Skip to content

Latest commit

 

History

History
276 lines (187 loc) · 11.6 KB

File metadata and controls

276 lines (187 loc) · 11.6 KB

OrganizationsV1

(OrganizationsV1)

Available Operations

AcceptInvite

Example Usage

using HathoraCloud;
using HathoraCloud.Models.Shared;
using HathoraCloud.Models.Operations;

var sdk = new HathoraCloudSDK(
    security: new Security() {
        HathoraDevToken = "<YOUR_BEARER_TOKEN_HERE>",
    },
    appId: "app-af469a92-5b45-4565-b3c4-b79878de67d2");

AcceptInviteRequest req = new AcceptInviteRequest() {
    OrgId = "org-6f706e83-0ec1-437a-9a46-7d4281eb2f39",
};


using(var res = await sdk.OrganizationsV1.AcceptInviteAsync(req))
{
    // handle response
}

Parameters

Parameter Type Required Description
request AcceptInviteRequest ✔️ The request object to use for the request.

Response

AcceptInviteResponse

Errors

Error Object Status Code Content Type
HathoraCloud.Models.Errors.ApiError 401,404,429 application/json
HathoraCloud.Models.Errors.SDKException 4xx-5xx /

GetOrgPendingInvites

Example Usage

using HathoraCloud;
using HathoraCloud.Models.Shared;
using HathoraCloud.Models.Operations;

var sdk = new HathoraCloudSDK(
    security: new Security() {
        HathoraDevToken = "<YOUR_BEARER_TOKEN_HERE>",
    },
    appId: "app-af469a92-5b45-4565-b3c4-b79878de67d2");

GetOrgPendingInvitesRequest req = new GetOrgPendingInvitesRequest() {
    OrgId = "org-6f706e83-0ec1-437a-9a46-7d4281eb2f39",
};


using(var res = await sdk.OrganizationsV1.GetOrgPendingInvitesAsync(req))
{
    // handle response
}

Parameters

Parameter Type Required Description
request GetOrgPendingInvitesRequest ✔️ The request object to use for the request.

Response

GetOrgPendingInvitesResponse

Errors

Error Object Status Code Content Type
HathoraCloud.Models.Errors.ApiError 401,429 application/json
HathoraCloud.Models.Errors.SDKException 4xx-5xx /

GetUserPendingInvites

Example Usage

using HathoraCloud;
using HathoraCloud.Models.Shared;

var sdk = new HathoraCloudSDK(
    security: new Security() {
        HathoraDevToken = "<YOUR_BEARER_TOKEN_HERE>",
    },
    appId: "app-af469a92-5b45-4565-b3c4-b79878de67d2");


using(var res = await sdk.OrganizationsV1.GetUserPendingInvitesAsync())
{
    // handle response
}

Response

GetUserPendingInvitesResponse

Errors

Error Object Status Code Content Type
HathoraCloud.Models.Errors.ApiError 401,429 application/json
HathoraCloud.Models.Errors.SDKException 4xx-5xx /

InviteUser

Example Usage

using HathoraCloud;
using HathoraCloud.Models.Shared;
using HathoraCloud.Models.Operations;

var sdk = new HathoraCloudSDK(
    security: new Security() {
        HathoraDevToken = "<YOUR_BEARER_TOKEN_HERE>",
    },
    appId: "app-af469a92-5b45-4565-b3c4-b79878de67d2");

InviteUserRequest req = new InviteUserRequest() {
    CreateUserInvite = new CreateUserInvite() {
        UserEmail = "<value>",
    },
    OrgId = "org-6f706e83-0ec1-437a-9a46-7d4281eb2f39",
};


using(var res = await sdk.OrganizationsV1.InviteUserAsync(req))
{
    // handle response
}

Parameters

Parameter Type Required Description
request InviteUserRequest ✔️ The request object to use for the request.

Response

InviteUserResponse

Errors

Error Object Status Code Content Type
HathoraCloud.Models.Errors.ApiError 401,422,429 application/json
HathoraCloud.Models.Errors.SDKException 4xx-5xx /

RejectInvite

Example Usage

using HathoraCloud;
using HathoraCloud.Models.Shared;
using HathoraCloud.Models.Operations;

var sdk = new HathoraCloudSDK(
    security: new Security() {
        HathoraDevToken = "<YOUR_BEARER_TOKEN_HERE>",
    },
    appId: "app-af469a92-5b45-4565-b3c4-b79878de67d2");

RejectInviteRequest req = new RejectInviteRequest() {
    OrgId = "org-6f706e83-0ec1-437a-9a46-7d4281eb2f39",
};


using(var res = await sdk.OrganizationsV1.RejectInviteAsync(req))
{
    // handle response
}

Parameters

Parameter Type Required Description
request RejectInviteRequest ✔️ The request object to use for the request.

Response

RejectInviteResponse

Errors

Error Object Status Code Content Type
HathoraCloud.Models.Errors.ApiError 401,404,429 application/json
HathoraCloud.Models.Errors.SDKException 4xx-5xx /

RescindInvite

Example Usage

using HathoraCloud;
using HathoraCloud.Models.Shared;
using HathoraCloud.Models.Operations;

var sdk = new HathoraCloudSDK(
    security: new Security() {
        HathoraDevToken = "<YOUR_BEARER_TOKEN_HERE>",
    },
    appId: "app-af469a92-5b45-4565-b3c4-b79878de67d2");

RescindInviteRequest req = new RescindInviteRequest() {
    RescindUserInvite = new RescindUserInvite() {
        UserEmail = "<value>",
    },
    OrgId = "org-6f706e83-0ec1-437a-9a46-7d4281eb2f39",
};


using(var res = await sdk.OrganizationsV1.RescindInviteAsync(req))
{
    // handle response
}

Parameters

Parameter Type Required Description
request RescindInviteRequest ✔️ The request object to use for the request.

Response

RescindInviteResponse

Errors

Error Object Status Code Content Type
HathoraCloud.Models.Errors.ApiError 401,404,429,500 application/json
HathoraCloud.Models.Errors.SDKException 4xx-5xx /