Skip to content

Latest commit

 

History

History
917 lines (583 loc) · 23 KB

TenantsApi.md

File metadata and controls

917 lines (583 loc) · 23 KB

\TenantsApi

All URIs are relative to https://api.basistheory.com

Method HTTP request Description
CreateConnection Post /tenants/self/connections
CreateInvitation Post /tenants/self/invitations
Delete Delete /tenants/self
DeleteConnection Delete /tenants/self/connections
DeleteInvitation Delete /tenants/self/invitations/{invitationId}
DeleteMember Delete /tenants/self/members/{memberId}
Get Get /tenants/self
GetInvitations Get /tenants/self/invitations
GetMembers Get /tenants/self/members
GetTenantUsageReport Get /tenants/self/reports/usage
OwnerGet Get /tenants/self/owner
ResendInvitation Post /tenants/self/invitations/{invitationId}/resend
Update Put /tenants/self
UpdateMember Put /tenants/self/members/{memberId}

CreateConnection

CreateTenantConnectionResponse CreateConnection(ctx).CreateTenantConnectionRequest(createTenantConnectionRequest).Execute()

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "./openapi"
)

func main() {
    createTenantConnectionRequest := *openapiclient.NewCreateTenantConnectionRequest("Strategy_example", *openapiclient.NewTenantConnectionOptions()) // CreateTenantConnectionRequest | 

    configuration := openapiclient.NewConfiguration()
    apiClient := openapiclient.NewAPIClient(configuration)
    resp, r, err := apiClient.TenantsApi.CreateConnection(context.Background()).CreateTenantConnectionRequest(createTenantConnectionRequest).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `TenantsApi.CreateConnection``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
    // response from `CreateConnection`: CreateTenantConnectionResponse
    fmt.Fprintf(os.Stdout, "Response from `TenantsApi.CreateConnection`: %v\n", resp)
}

Path Parameters

Other Parameters

Other parameters are passed through a pointer to a apiCreateConnectionRequest struct via the builder pattern

Name Type Description Notes
createTenantConnectionRequest CreateTenantConnectionRequest

Return type

CreateTenantConnectionResponse

Authorization

ApiKey

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

CreateInvitation

TenantInvitationResponse CreateInvitation(ctx).CreateTenantInvitationRequest(createTenantInvitationRequest).Execute()

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "./openapi"
)

func main() {
    createTenantInvitationRequest := *openapiclient.NewCreateTenantInvitationRequest("Email_example") // CreateTenantInvitationRequest | 

    configuration := openapiclient.NewConfiguration()
    apiClient := openapiclient.NewAPIClient(configuration)
    resp, r, err := apiClient.TenantsApi.CreateInvitation(context.Background()).CreateTenantInvitationRequest(createTenantInvitationRequest).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `TenantsApi.CreateInvitation``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
    // response from `CreateInvitation`: TenantInvitationResponse
    fmt.Fprintf(os.Stdout, "Response from `TenantsApi.CreateInvitation`: %v\n", resp)
}

Path Parameters

Other Parameters

Other parameters are passed through a pointer to a apiCreateInvitationRequest struct via the builder pattern

Name Type Description Notes
createTenantInvitationRequest CreateTenantInvitationRequest

Return type

TenantInvitationResponse

Authorization

ApiKey

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

Delete

Delete(ctx).Execute()

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "./openapi"
)

func main() {

    configuration := openapiclient.NewConfiguration()
    apiClient := openapiclient.NewAPIClient(configuration)
    r, err := apiClient.TenantsApi.Delete(context.Background()).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `TenantsApi.Delete``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
}

Path Parameters

This endpoint does not need any parameter.

Other Parameters

Other parameters are passed through a pointer to a apiDeleteRequest struct via the builder pattern

Return type

(empty response body)

Authorization

ApiKey

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

DeleteConnection

CreateTenantConnectionResponse DeleteConnection(ctx).Execute()

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "./openapi"
)

func main() {

    configuration := openapiclient.NewConfiguration()
    apiClient := openapiclient.NewAPIClient(configuration)
    resp, r, err := apiClient.TenantsApi.DeleteConnection(context.Background()).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `TenantsApi.DeleteConnection``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
    // response from `DeleteConnection`: CreateTenantConnectionResponse
    fmt.Fprintf(os.Stdout, "Response from `TenantsApi.DeleteConnection`: %v\n", resp)
}

Path Parameters

This endpoint does not need any parameter.

Other Parameters

Other parameters are passed through a pointer to a apiDeleteConnectionRequest struct via the builder pattern

Return type

CreateTenantConnectionResponse

Authorization

ApiKey

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

DeleteInvitation

DeleteInvitation(ctx, invitationId).Execute()

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "./openapi"
)

func main() {
    invitationId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | 

    configuration := openapiclient.NewConfiguration()
    apiClient := openapiclient.NewAPIClient(configuration)
    r, err := apiClient.TenantsApi.DeleteInvitation(context.Background(), invitationId).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `TenantsApi.DeleteInvitation``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
}

Path Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
invitationId string

Other Parameters

Other parameters are passed through a pointer to a apiDeleteInvitationRequest struct via the builder pattern

Name Type Description Notes

Return type

(empty response body)

Authorization

ApiKey

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

DeleteMember

DeleteMember(ctx, memberId).Execute()

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "./openapi"
)

func main() {
    memberId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | 

    configuration := openapiclient.NewConfiguration()
    apiClient := openapiclient.NewAPIClient(configuration)
    r, err := apiClient.TenantsApi.DeleteMember(context.Background(), memberId).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `TenantsApi.DeleteMember``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
}

Path Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
memberId string

Other Parameters

Other parameters are passed through a pointer to a apiDeleteMemberRequest struct via the builder pattern

Name Type Description Notes

Return type

(empty response body)

Authorization

ApiKey

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

Get

Tenant Get(ctx).Execute()

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "./openapi"
)

func main() {

    configuration := openapiclient.NewConfiguration()
    apiClient := openapiclient.NewAPIClient(configuration)
    resp, r, err := apiClient.TenantsApi.Get(context.Background()).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `TenantsApi.Get``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
    // response from `Get`: Tenant
    fmt.Fprintf(os.Stdout, "Response from `TenantsApi.Get`: %v\n", resp)
}

Path Parameters

This endpoint does not need any parameter.

Other Parameters

Other parameters are passed through a pointer to a apiGetRequest struct via the builder pattern

Return type

Tenant

Authorization

ApiKey

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetInvitations

TenantInvitationResponsePaginatedList GetInvitations(ctx).Status(status).Page(page).Start(start).Size(size).Execute()

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "./openapi"
)

func main() {
    status := openapiclient.TenantInvitationStatus("PENDING") // TenantInvitationStatus |  (optional)
    page := int32(56) // int32 |  (optional)
    start := "start_example" // string |  (optional)
    size := int32(56) // int32 |  (optional)

    configuration := openapiclient.NewConfiguration()
    apiClient := openapiclient.NewAPIClient(configuration)
    resp, r, err := apiClient.TenantsApi.GetInvitations(context.Background()).Status(status).Page(page).Start(start).Size(size).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `TenantsApi.GetInvitations``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
    // response from `GetInvitations`: TenantInvitationResponsePaginatedList
    fmt.Fprintf(os.Stdout, "Response from `TenantsApi.GetInvitations`: %v\n", resp)
}

Path Parameters

Other Parameters

Other parameters are passed through a pointer to a apiGetInvitationsRequest struct via the builder pattern

Name Type Description Notes
status TenantInvitationStatus
page int32
start string
size int32

Return type

TenantInvitationResponsePaginatedList

Authorization

ApiKey

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetMembers

TenantMemberResponsePaginatedList GetMembers(ctx).UserId(userId).Page(page).Start(start).Size(size).Execute()

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "./openapi"
)

func main() {
    userId := []string{"Inner_example"} // []string |  (optional)
    page := int32(56) // int32 |  (optional)
    start := "start_example" // string |  (optional)
    size := int32(56) // int32 |  (optional)

    configuration := openapiclient.NewConfiguration()
    apiClient := openapiclient.NewAPIClient(configuration)
    resp, r, err := apiClient.TenantsApi.GetMembers(context.Background()).UserId(userId).Page(page).Start(start).Size(size).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `TenantsApi.GetMembers``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
    // response from `GetMembers`: TenantMemberResponsePaginatedList
    fmt.Fprintf(os.Stdout, "Response from `TenantsApi.GetMembers`: %v\n", resp)
}

Path Parameters

Other Parameters

Other parameters are passed through a pointer to a apiGetMembersRequest struct via the builder pattern

Name Type Description Notes
userId []string
page int32
start string
size int32

Return type

TenantMemberResponsePaginatedList

Authorization

ApiKey

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetTenantUsageReport

TenantUsageReport GetTenantUsageReport(ctx).Execute()

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "./openapi"
)

func main() {

    configuration := openapiclient.NewConfiguration()
    apiClient := openapiclient.NewAPIClient(configuration)
    resp, r, err := apiClient.TenantsApi.GetTenantUsageReport(context.Background()).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `TenantsApi.GetTenantUsageReport``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
    // response from `GetTenantUsageReport`: TenantUsageReport
    fmt.Fprintf(os.Stdout, "Response from `TenantsApi.GetTenantUsageReport`: %v\n", resp)
}

Path Parameters

This endpoint does not need any parameter.

Other Parameters

Other parameters are passed through a pointer to a apiGetTenantUsageReportRequest struct via the builder pattern

Return type

TenantUsageReport

Authorization

ApiKey

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

OwnerGet

TenantMemberResponse OwnerGet(ctx).Execute()

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "./openapi"
)

func main() {

    configuration := openapiclient.NewConfiguration()
    apiClient := openapiclient.NewAPIClient(configuration)
    resp, r, err := apiClient.TenantsApi.OwnerGet(context.Background()).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `TenantsApi.OwnerGet``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
    // response from `OwnerGet`: TenantMemberResponse
    fmt.Fprintf(os.Stdout, "Response from `TenantsApi.OwnerGet`: %v\n", resp)
}

Path Parameters

This endpoint does not need any parameter.

Other Parameters

Other parameters are passed through a pointer to a apiOwnerGetRequest struct via the builder pattern

Return type

TenantMemberResponse

Authorization

ApiKey

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

ResendInvitation

TenantInvitationResponse ResendInvitation(ctx, invitationId).Execute()

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "./openapi"
)

func main() {
    invitationId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | 

    configuration := openapiclient.NewConfiguration()
    apiClient := openapiclient.NewAPIClient(configuration)
    resp, r, err := apiClient.TenantsApi.ResendInvitation(context.Background(), invitationId).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `TenantsApi.ResendInvitation``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
    // response from `ResendInvitation`: TenantInvitationResponse
    fmt.Fprintf(os.Stdout, "Response from `TenantsApi.ResendInvitation`: %v\n", resp)
}

Path Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
invitationId string

Other Parameters

Other parameters are passed through a pointer to a apiResendInvitationRequest struct via the builder pattern

Name Type Description Notes

Return type

TenantInvitationResponse

Authorization

ApiKey

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

Update

Tenant Update(ctx).UpdateTenantRequest(updateTenantRequest).Execute()

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "./openapi"
)

func main() {
    updateTenantRequest := *openapiclient.NewUpdateTenantRequest("Name_example") // UpdateTenantRequest | 

    configuration := openapiclient.NewConfiguration()
    apiClient := openapiclient.NewAPIClient(configuration)
    resp, r, err := apiClient.TenantsApi.Update(context.Background()).UpdateTenantRequest(updateTenantRequest).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `TenantsApi.Update``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
    // response from `Update`: Tenant
    fmt.Fprintf(os.Stdout, "Response from `TenantsApi.Update`: %v\n", resp)
}

Path Parameters

Other Parameters

Other parameters are passed through a pointer to a apiUpdateRequest struct via the builder pattern

Name Type Description Notes
updateTenantRequest UpdateTenantRequest

Return type

Tenant

Authorization

ApiKey

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

UpdateMember

TenantMemberResponse UpdateMember(ctx, memberId).UpdateTenantMemberRequest(updateTenantMemberRequest).Execute()

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "./openapi"
)

func main() {
    memberId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | 
    updateTenantMemberRequest := *openapiclient.NewUpdateTenantMemberRequest("Role_example") // UpdateTenantMemberRequest |  (optional)

    configuration := openapiclient.NewConfiguration()
    apiClient := openapiclient.NewAPIClient(configuration)
    resp, r, err := apiClient.TenantsApi.UpdateMember(context.Background(), memberId).UpdateTenantMemberRequest(updateTenantMemberRequest).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `TenantsApi.UpdateMember``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
    // response from `UpdateMember`: TenantMemberResponse
    fmt.Fprintf(os.Stdout, "Response from `TenantsApi.UpdateMember`: %v\n", resp)
}

Path Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
memberId string

Other Parameters

Other parameters are passed through a pointer to a apiUpdateMemberRequest struct via the builder pattern

Name Type Description Notes

updateTenantMemberRequest | UpdateTenantMemberRequest | |

Return type

TenantMemberResponse

Authorization

ApiKey

HTTP request headers

  • Content-Type: application/json-patch+json, application/json, text/json, application/+json, application/xml, text/xml, application/+xml
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]