Skip to content

Latest commit

 

History

History
854 lines (567 loc) · 21 KB

TeamApi.md

File metadata and controls

854 lines (567 loc) · 21 KB

TeamApi

All URIs are relative to https://api.hellosign.com/v3.

Method HTTP request Description
teamAddMember() PUT /team/add_member Add User to Team
teamCreate() POST /team/create Create Team
teamDelete() DELETE /team/destroy Delete Team
teamGet() GET /team Get Team
teamInfo() GET /team/info Get Team Info
teamInvites() GET /team/invites List Team Invites
teamMembers() GET /team/members/{team_id} List Team Members
teamRemoveMember() POST /team/remove_member Remove User from Team
teamSubTeams() GET /team/sub_teams/{team_id} List Sub Teams
teamUpdate() PUT /team Update Team

teamAddMember()

teamAddMember(teamAddMemberRequest: TeamAddMemberRequest, teamId: string): TeamGetResponse

Add User to Team

Invites a user (specified using the email_address parameter) to your Team. If the user does not currently have a Dropbox Sign Account, a new one will be created for them. If a user is already a part of another Team, a team_invite_failed error will be returned.

TypeScript Example

import * as DropboxSign from "@dropbox/sign";

const teamApi = new DropboxSign.TeamApi();

// Configure HTTP basic authorization: api_key
teamApi.username = "YOUR_API_KEY";

// or, configure Bearer (JWT) authorization: oauth2
// teamApi.accessToken = "YOUR_ACCESS_TOKEN";

const data: DropboxSign.TeamAddMemberRequest = {
  emailAddress: "[email protected]",
};

const result = teamApi.teamAddMember(data);
result.then(response => {
  console.log(response.body);
}).catch(error => {
  console.log("Exception when calling Dropbox Sign API:");
  console.log(error.body);
});

JavaScript Example

import * as DropboxSign from "@dropbox/sign";

const teamApi = new DropboxSign.TeamApi();

// Configure HTTP basic authorization: api_key
teamApi.username = "YOUR_API_KEY";

// or, configure Bearer (JWT) authorization: oauth2
// teamApi.accessToken = "YOUR_ACCESS_TOKEN";

const data = {
  emailAddress: "[email protected]",
};

const result = teamApi.teamAddMember(data);
result.then(response => {
  console.log(response.body);
}).catch(error => {
  console.log("Exception when calling Dropbox Sign API:");
  console.log(error.body);
});

Parameters

Name Type Description Notes
teamAddMemberRequest TeamAddMemberRequest
teamId string The id of the team. [optional]

Return type

TeamGetResponse

Authorization

api_key, oauth2

HTTP request headers

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

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

teamCreate()

teamCreate(teamCreateRequest: TeamCreateRequest): TeamGetResponse

Create Team

Creates a new Team and makes you a member. You must not currently belong to a Team to invoke.

TypeScript Example

import * as DropboxSign from "@dropbox/sign";

const teamApi = new DropboxSign.TeamApi();

// Configure HTTP basic authorization: api_key
teamApi.username = "YOUR_API_KEY";

// or, configure Bearer (JWT) authorization: oauth2
// teamApi.accessToken = "YOUR_ACCESS_TOKEN";

const data: DropboxSign.TeamCreateRequest = {
  name: "New Team Name"
};

const result = teamApi.teamCreate(data);
result.then(response => {
  console.log(response.body);
}).catch(error => {
  console.log("Exception when calling Dropbox Sign API:");
  console.log(error.body);
});

JavaScript Example

import * as DropboxSign from "@dropbox/sign";

const teamApi = new DropboxSign.TeamApi();

// Configure HTTP basic authorization: api_key
teamApi.username = "YOUR_API_KEY";

// or, configure Bearer (JWT) authorization: oauth2
// teamApi.accessToken = "YOUR_ACCESS_TOKEN";

const data = {
  name: "New Team Name"
};

const result = teamApi.teamCreate(data);
result.then(response => {
  console.log(response.body);
}).catch(error => {
  console.log("Exception when calling Dropbox Sign API:");
  console.log(error.body);
});

Parameters

Name Type Description Notes
teamCreateRequest TeamCreateRequest

Return type

TeamGetResponse

Authorization

api_key, oauth2

HTTP request headers

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

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

teamDelete()

teamDelete()

Delete Team

Deletes your Team. Can only be invoked when you have a Team with only one member (yourself).

TypeScript Example

import * as DropboxSign from "@dropbox/sign";

const teamApi = new DropboxSign.TeamApi();

// Configure HTTP basic authorization: api_key
teamApi.username = "YOUR_API_KEY";

// or, configure Bearer (JWT) authorization: oauth2
// teamApi.accessToken = "YOUR_ACCESS_TOKEN";

const result = teamApi.teamDelete();
result.then(response => {
  console.log(response.body);
}).catch(error => {
  console.log("Exception when calling Dropbox Sign API:");
  console.log(error.body);
});

JavaScript Example

import * as DropboxSign from "@dropbox/sign";

const teamApi = new DropboxSign.TeamApi();

// Configure HTTP basic authorization: api_key
teamApi.username = "YOUR_API_KEY";

// or, configure Bearer (JWT) authorization: oauth2
// teamApi.accessToken = "YOUR_ACCESS_TOKEN";

const result = teamApi.teamDelete();
result.then(response => {
  console.log(response.body);
}).catch(error => {
  console.log("Exception when calling Dropbox Sign API:");
  console.log(error.body);
});

Parameters

|This endpoint does not need any parameter. |

Return type

void (empty response body)

Authorization

api_key, oauth2

HTTP request headers

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

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

teamGet()

teamGet(): TeamGetResponse

Get Team

Returns information about your Team as well as a list of its members. If you do not belong to a Team, a 404 error with an error_name of "not_found" will be returned.

TypeScript Example

import * as DropboxSign from "@dropbox/sign";

const teamApi = new DropboxSign.TeamApi();

// Configure HTTP basic authorization: api_key
teamApi.username = "YOUR_API_KEY";

// or, configure Bearer (JWT) authorization: oauth2
// teamApi.accessToken = "YOUR_ACCESS_TOKEN";

const result = teamApi.teamGet();
result.then(response => {
  console.log(response.body);
}).catch(error => {
  console.log("Exception when calling Dropbox Sign API:");
  console.log(error.body);
});

JavaScript Example

import * as DropboxSign from "@dropbox/sign";

const teamApi = new DropboxSign.TeamApi();

// Configure HTTP basic authorization: api_key
teamApi.username = "YOUR_API_KEY";

// or, configure Bearer (JWT) authorization: oauth2
// teamApi.accessToken = "YOUR_ACCESS_TOKEN";

const result = teamApi.teamGet();
result.then(response => {
  console.log(response.body);
}).catch(error => {
  console.log("Exception when calling Dropbox Sign API:");
  console.log(error.body);
});

Parameters

|This endpoint does not need any parameter. |

Return type

TeamGetResponse

Authorization

api_key, oauth2

HTTP request headers

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

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

teamInfo()

teamInfo(teamId: string): TeamGetInfoResponse

Get Team Info

Provides information about a team.

TypeScript Example

import * as DropboxSign from "@dropbox/sign";

const teamApi = new DropboxSign.TeamApi();

// Configure HTTP basic authorization: api_key
teamApi.username = "YOUR_API_KEY";

// or, configure Bearer (JWT) authorization: oauth2
// teamApi.accessToken = "YOUR_ACCESS_TOKEN";

const result = teamApi.teamInfo();
result.then(response => {
  console.log(response.body);
}).catch(error => {
  console.log("Exception when calling Dropbox Sign API:");
  console.log(error.body);
});

JavaScript Example

import * as DropboxSign from "@dropbox/sign";

const teamApi = new DropboxSign.TeamApi();

// Configure HTTP basic authorization: api_key
teamApi.username = "YOUR_API_KEY";

// or, configure Bearer (JWT) authorization: oauth2
// teamApi.accessToken = "YOUR_ACCESS_TOKEN";

const result = teamApi.teamInfo();
result.then(response => {
  console.log(response.body);
}).catch(error => {
  console.log("Exception when calling Dropbox Sign API:");
  console.log(error.body);
});

Parameters

Name Type Description Notes
teamId string The id of the team. [optional]

Return type

TeamGetInfoResponse

Authorization

api_key, oauth2

HTTP request headers

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

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

teamInvites()

teamInvites(emailAddress: string): TeamInvitesResponse

List Team Invites

Provides a list of team invites (and their roles).

TypeScript Example

import * as DropboxSign from "@dropbox/sign";

const teamApi = new DropboxSign.TeamApi();

// Configure HTTP basic authorization: api_key
teamApi.username = "YOUR_API_KEY";

// or, configure Bearer (JWT) authorization: oauth2
// teamApi.accessToken = "YOUR_ACCESS_TOKEN";

const emailAddress = "[email protected]";

const result = teamApi.teamInvites(emailAddress);
result.then(response => {
  console.log(response.body);
}).catch(error => {
  console.log("Exception when calling Dropbox Sign API:");
  console.log(error.body);
});

JavaScript Example

import * as DropboxSign from "@dropbox/sign";

const teamApi = new DropboxSign.TeamApi();

// Configure HTTP basic authorization: api_key
teamApi.username = "YOUR_API_KEY";

// or, configure Bearer (JWT) authorization: oauth2
// teamApi.accessToken = "YOUR_ACCESS_TOKEN";

const emailAddress = "[email protected]";

const result = teamApi.teamInvites(emailAddress);
result.then(response => {
  console.log(response.body);
}).catch(error => {
  console.log("Exception when calling Dropbox Sign API:");
  console.log(error.body);
});

Parameters

Name Type Description Notes
emailAddress string The email address for which to display the team invites. [optional]

Return type

TeamInvitesResponse

Authorization

api_key, oauth2

HTTP request headers

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

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

teamMembers()

teamMembers(teamId: string, page: number, pageSize: number): TeamMembersResponse

List Team Members

Provides a paginated list of members (and their roles) that belong to a given team.

TypeScript Example

import * as DropboxSign from "@dropbox/sign";

const teamApi = new DropboxSign.TeamApi();

// Configure HTTP basic authorization: api_key
teamApi.username = "YOUR_API_KEY";

// or, configure Bearer (JWT) authorization: oauth2
// teamApi.accessToken = "YOUR_ACCESS_TOKEN";

const teamId = "4fea99bfcf2b26bfccf6cea3e127fb8bb74d8d9c";

const result = teamApi.teamMembers(teamId);
result.then(response => {
  console.log(response.body);
}).catch(error => {
  console.log("Exception when calling Dropbox Sign API:");
  console.log(error.body);
});

JavaScript Example

import * as DropboxSign from "@dropbox/sign";

const teamApi = new DropboxSign.TeamApi();

// Configure HTTP basic authorization: api_key
teamApi.username = "YOUR_API_KEY";

// or, configure Bearer (JWT) authorization: oauth2
// teamApi.accessToken = "YOUR_ACCESS_TOKEN";

const teamId = "4fea99bfcf2b26bfccf6cea3e127fb8bb74d8d9c";

const result = teamApi.teamMembers(teamId);
result.then(response => {
  console.log(response.body);
}).catch(error => {
  console.log("Exception when calling Dropbox Sign API:");
  console.log(error.body);
});

Parameters

Name Type Description Notes
teamId string The id of the team that a member list is being requested from.
page number Which page number of the team member list to return. Defaults to 1. [optional] [default to 1]
pageSize number Number of objects to be returned per page. Must be between 1 and 100. Default is 20. [optional] [default to 20]

Return type

TeamMembersResponse

Authorization

api_key, oauth2

HTTP request headers

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

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

teamRemoveMember()

teamRemoveMember(teamRemoveMemberRequest: TeamRemoveMemberRequest): TeamGetResponse

Remove User from Team

Removes the provided user Account from your Team. If the Account had an outstanding invitation to your Team, the invitation will be expired. If you choose to transfer documents from the removed Account to an Account provided in the new_owner_email_address parameter (available only for Enterprise plans), the response status code will be 201, which indicates that your request has been queued but not fully executed.

TypeScript Example

import * as DropboxSign from "@dropbox/sign";

const teamApi = new DropboxSign.TeamApi();

// Configure HTTP basic authorization: api_key
teamApi.username = "YOUR_API_KEY";

// or, configure Bearer (JWT) authorization: oauth2
// teamApi.accessToken = "YOUR_ACCESS_TOKEN";

const data: DropboxSign.TeamRemoveMemberRequest = {
  emailAddress: "[email protected]",
  newOwnerEmailAddress: "[email protected]",
};

const result = teamApi.teamRemoveMember(data);
result.then(response => {
  console.log(response.body);
}).catch(error => {
  console.log("Exception when calling Dropbox Sign API:");
  console.log(error.body);
});

JavaScript Example

import * as DropboxSign from "@dropbox/sign";

const teamApi = new DropboxSign.TeamApi();

// Configure HTTP basic authorization: api_key
teamApi.username = "YOUR_API_KEY";

// or, configure Bearer (JWT) authorization: oauth2
// teamApi.accessToken = "YOUR_ACCESS_TOKEN";

const data = {
  emailAddress: "[email protected]",
  newOwnerEmailAddress: "[email protected]",
};

const result = teamApi.teamRemoveMember(data);
result.then(response => {
  console.log(response.body);
}).catch(error => {
  console.log("Exception when calling Dropbox Sign API:");
  console.log(error.body);
});

Parameters

Name Type Description Notes
teamRemoveMemberRequest TeamRemoveMemberRequest

Return type

TeamGetResponse

Authorization

api_key, oauth2

HTTP request headers

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

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

teamSubTeams()

teamSubTeams(teamId: string, page: number, pageSize: number): TeamSubTeamsResponse

List Sub Teams

Provides a paginated list of sub teams that belong to a given team.

TypeScript Example

import * as DropboxSign from "@dropbox/sign";

const teamApi = new DropboxSign.TeamApi();

// Configure HTTP basic authorization: api_key
teamApi.username = "YOUR_API_KEY";

// or, configure Bearer (JWT) authorization: oauth2
// teamApi.accessToken = "YOUR_ACCESS_TOKEN";

const teamId = "4fea99bfcf2b26bfccf6cea3e127fb8bb74d8d9c";

const result = teamApi.teamSubTeams(teamId);
result.then(response => {
  console.log(response.body);
}).catch(error => {
  console.log("Exception when calling Dropbox Sign API:");
  console.log(error.body);
});

JavaScript Example

import * as DropboxSign from "@dropbox/sign";

const teamApi = new DropboxSign.TeamApi();

// Configure HTTP basic authorization: api_key
teamApi.username = "YOUR_API_KEY";

// or, configure Bearer (JWT) authorization: oauth2
// teamApi.accessToken = "YOUR_ACCESS_TOKEN";

const teamId = "4fea99bfcf2b26bfccf6cea3e127fb8bb74d8d9c";

const result = teamApi.teamSubTeams(teamId);
result.then(response => {
  console.log(response.body);
}).catch(error => {
  console.log("Exception when calling Dropbox Sign API:");
  console.log(error.body);
});

Parameters

Name Type Description Notes
teamId string The id of the parent Team.
page number Which page number of the SubTeam List to return. Defaults to 1. [optional] [default to 1]
pageSize number Number of objects to be returned per page. Must be between 1 and 100. Default is 20. [optional] [default to 20]

Return type

TeamSubTeamsResponse

Authorization

api_key, oauth2

HTTP request headers

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

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

teamUpdate()

teamUpdate(teamUpdateRequest: TeamUpdateRequest): TeamGetResponse

Update Team

Updates the name of your Team.

TypeScript Example

import * as DropboxSign from "@dropbox/sign";

const teamApi = new DropboxSign.TeamApi();

// Configure HTTP basic authorization: api_key
teamApi.username = "YOUR_API_KEY";

// or, configure Bearer (JWT) authorization: oauth2
// teamApi.accessToken = "YOUR_ACCESS_TOKEN";

const data: DropboxSign.TeamUpdateRequest = {
  name: "New Team Name",
};

const result = teamApi.teamUpdate(data);
result.then(response => {
  console.log(response.body);
}).catch(error => {
  console.log("Exception when calling Dropbox Sign API:");
  console.log(error.body);
});

JavaScript Example

import * as DropboxSign from "@dropbox/sign";

const teamApi = new DropboxSign.TeamApi();

// Configure HTTP basic authorization: api_key
teamApi.username = "YOUR_API_KEY";

// or, configure Bearer (JWT) authorization: oauth2
// teamApi.accessToken = "YOUR_ACCESS_TOKEN";

const data = {
  name: "New Team Name",
};

const result = teamApi.teamUpdate(data);
result.then(response => {
  console.log(response.body);
}).catch(error => {
  console.log("Exception when calling Dropbox Sign API:");
  console.log(error.body);
});

Parameters

Name Type Description Notes
teamUpdateRequest TeamUpdateRequest

Return type

TeamGetResponse

Authorization

api_key, oauth2

HTTP request headers

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

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