Skip to content

Commit

Permalink
Merge pull request #40 from PandaDoc/v6.2.0
Browse files Browse the repository at this point in the history
v6.2.0
  • Loading branch information
evsazonov authored Apr 5, 2024
2 parents 5fab538 + c7740bf commit dcfc338
Show file tree
Hide file tree
Showing 34 changed files with 1,694 additions and 27 deletions.
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ Class | Method | HTTP request | Description
*DocumentAttachmentsApi* | [**listDocumentAttachments**](docs/DocumentAttachmentsApi.md#listdocumentattachments) | **GET** /public/v1/documents/{id}/attachments | Document Attachment List
*DocumentRecipientsApi* | [**addDocumentRecipient**](docs/DocumentRecipientsApi.md#adddocumentrecipient) | **POST** /public/v1/documents/{id}/recipients | Add Document Recipient
*DocumentRecipientsApi* | [**deleteDocumentRecipient**](docs/DocumentRecipientsApi.md#deletedocumentrecipient) | **DELETE** /public/v1/documents/{id}/recipients/{recipient_id} | Delete Document Recipient
*DocumentRecipientsApi* | [**editDocumentRecipient**](docs/DocumentRecipientsApi.md#editdocumentrecipient) | **PATCH** /public/v1/documents/{id}/recipients/{recipient_id} | Edit Document Recipient
*DocumentRecipientsApi* | [**editDocumentRecipient**](docs/DocumentRecipientsApi.md#editdocumentrecipient) | **PATCH** /public/v1/documents/{id}/recipients/recipient/{recipient_id} | Edit Document Recipient
*DocumentRecipientsApi* | [**reassignDocumentRecipient**](docs/DocumentRecipientsApi.md#reassigndocumentrecipient) | **POST** /public/v1/documents/{id}/recipients/{recipient_id}/reassign | Reassign Document Recipient
*DocumentsApi* | [**changeDocumentStatus**](docs/DocumentsApi.md#changedocumentstatus) | **PATCH** /public/v1/documents/{id}/status | Document status change
*DocumentsApi* | [**createDocument**](docs/DocumentsApi.md#createdocument) | **POST** /public/v1/documents | Create document
Expand Down Expand Up @@ -112,6 +112,9 @@ Class | Method | HTTP request | Description
*TemplatesApi* | [**deleteTemplate**](docs/TemplatesApi.md#deletetemplate) | **DELETE** /public/v1/templates/{id} | Delete Template
*TemplatesApi* | [**detailsTemplate**](docs/TemplatesApi.md#detailstemplate) | **GET** /public/v1/templates/{id}/details | Details Template
*TemplatesApi* | [**listTemplates**](docs/TemplatesApi.md#listtemplates) | **GET** /public/v1/templates | List Templates
*UserAndWorkspaceManagementApi* | [**addMember**](docs/UserAndWorkspaceManagementApi.md#addmember) | **POST** /public/v1/workspaces/{workspace_id}/members | Add member
*UserAndWorkspaceManagementApi* | [**createUser**](docs/UserAndWorkspaceManagementApi.md#createuser) | **POST** /public/v1/users | Create User
*UserAndWorkspaceManagementApi* | [**createWorkspace**](docs/UserAndWorkspaceManagementApi.md#createworkspace) | **POST** /public/v1/workspaces | Create Workspace
*WebhookEventsApi* | [**detailsWebhookEvent**](docs/WebhookEventsApi.md#detailswebhookevent) | **GET** /public/v1/webhook-events/{id} | Get webhook event by uuid
*WebhookEventsApi* | [**listWebhookEvent**](docs/WebhookEventsApi.md#listwebhookevent) | **GET** /public/v1/webhook-events | Get webhook event page
*WebhookSubscriptionsApi* | [**createWebhookSubscription**](docs/WebhookSubscriptionsApi.md#createwebhooksubscription) | **POST** /public/v1/webhook-subscriptions | Create webhook subscription
Expand Down
12 changes: 10 additions & 2 deletions docs/DocumentRecipientsApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Method | HTTP request | Description
------------- | ------------- | -------------
[**addDocumentRecipient**](DocumentRecipientsApi.md#addDocumentRecipient) | **POST** /public/v1/documents/{id}/recipients | Add Document Recipient
[**deleteDocumentRecipient**](DocumentRecipientsApi.md#deleteDocumentRecipient) | **DELETE** /public/v1/documents/{id}/recipients/{recipient_id} | Delete Document Recipient
[**editDocumentRecipient**](DocumentRecipientsApi.md#editDocumentRecipient) | **PATCH** /public/v1/documents/{id}/recipients/{recipient_id} | Edit Document Recipient
[**editDocumentRecipient**](DocumentRecipientsApi.md#editDocumentRecipient) | **PATCH** /public/v1/documents/{id}/recipients/recipient/{recipient_id} | Edit Document Recipient
[**reassignDocumentRecipient**](DocumentRecipientsApi.md#reassignDocumentRecipient) | **POST** /public/v1/documents/{id}/recipients/{recipient_id}/reassign | Reassign Document Recipient


Expand Down Expand Up @@ -168,11 +168,15 @@ const body:pd_api.DocumentRecipientsApiEditDocumentRecipientRequest = {
// DocumentRecipientEditRequest
documentRecipientEditRequest: {
email: "[email protected]",
phone: "+14842634627",
deliveryMethods: {
email: true,
sms: false,
},
firstName: "John",
lastName: "Doe",
company: "John Doe Inc.",
jobTitle: "CTO",
phone: "+14842634627",
state: "Texas",
streetAddress: "1313 Mockingbird Lane",
city: "Austin",
Expand All @@ -186,6 +190,10 @@ const body:pd_api.DocumentRecipientsApiEditDocumentRecipientRequest = {
phoneNumber: "+1234567890",
},
},
redirect: {
isEnabled: true,
url: "https://example.com",
},
},
};

Expand Down
27 changes: 27 additions & 0 deletions docs/DocumentsApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,10 +121,19 @@ const body:pd_api.DocumentsApiCreateDocumentRequest = {
recipients: [
{
email: "[email protected]",
phone: "+14842634627",
deliveryMethods: {
email: true,
sms: false,
},
firstName: "Josh",
lastName: "Ron",
role: "user",
signingOrder: 1,
redirect: {
isEnabled: true,
url: "https://example.com",
},
},
],
tokens: [
Expand Down Expand Up @@ -202,10 +211,19 @@ const body:pd_api.DocumentsApiCreateDocumentRequest = {
recipients: [
{
email: "[email protected]",
phone: "+14842634627",
deliveryMethods: {
email: true,
sms: false,
},
firstName: "Josh",
lastName: "Ron",
role: "user",
signingOrder: 1,
redirect: {
isEnabled: true,
url: "https://example.com",
},
},
],
},
Expand Down Expand Up @@ -1268,8 +1286,17 @@ const body:pd_api.DocumentsApiUpdateDocumentRequest = {
{
id: "id_example",
email: "[email protected]",
phone: "+14842634627",
firstName: "Josh",
lastName: "Ron",
deliveryMethods: {
email: true,
sms: false,
},
redirect: {
isEnabled: true,
url: "https://example.com",
},
},
],
fields: {},
Expand Down
21 changes: 21 additions & 0 deletions docs/SectionsApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -225,10 +225,19 @@ const body:pd_api.SectionsApiUploadSectionRequest = {
recipients: [
{
email: "[email protected]",
phone: "+14842634627",
deliveryMethods: {
email: true,
sms: false,
},
firstName: "Josh",
lastName: "Ron",
role: "user",
signingOrder: 1,
redirect: {
isEnabled: true,
url: "https://example.com",
},
},
],
tokens: [
Expand Down Expand Up @@ -299,10 +308,19 @@ const body:pd_api.SectionsApiUploadSectionRequest = {
recipients: [
{
email: "[email protected]",
phone: "+14842634627",
deliveryMethods: {
email: true,
sms: false,
},
firstName: "Josh",
lastName: "Ron",
role: "user",
signingOrder: 1,
redirect: {
isEnabled: true,
url: "https://example.com",
},
},
],
},
Expand All @@ -312,6 +330,8 @@ const body:pd_api.SectionsApiUploadSectionRequest = {
url: "https://s3.amazonaws.com/pd-static-content/public-docs/pandadoc-panda-bear.png",
parseFormFields: true,
},
// 'document' | 'upload' | Determines how the fields are mapped when creating a section. * document: Default value. The fields of the entire document are updated. * upload: Only the fields from the created section are updated. The merge field is appended with the upload ID. (optional)
mergeFieldScope: "document",
};

apiInstance.uploadSection(body).then((data) => {
Expand All @@ -326,6 +346,7 @@ Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**uploadSectionRequest** | **UploadSectionRequest**| Use a PandaDoc template or an existing PDF to upload a section. See the creation request examples [by template](/schemas/UploadSectionByTemplateRequest) and [by pdf](/schemas/UploadSectionByPdfRequest) |
**documentId** | [**string**] | Document ID | defaults to undefined
**mergeFieldScope** | [**&#39;document&#39; | &#39;upload&#39;**]**Array<&#39;document&#39; &#124; &#39;upload&#39;>** | Determines how the fields are mapped when creating a section. * document: Default value. The fields of the entire document are updated. * upload: Only the fields from the created section are updated. The merge field is appended with the upload ID. | (optional) defaults to undefined


### Return type
Expand Down
227 changes: 227 additions & 0 deletions docs/UserAndWorkspaceManagementApi.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,227 @@
# .UserAndWorkspaceManagementApi

All URIs are relative to *https://api.pandadoc.com*

Method | HTTP request | Description
------------- | ------------- | -------------
[**addMember**](UserAndWorkspaceManagementApi.md#addMember) | **POST** /public/v1/workspaces/{workspace_id}/members | Add member
[**createUser**](UserAndWorkspaceManagementApi.md#createUser) | **POST** /public/v1/users | Create User
[**createWorkspace**](UserAndWorkspaceManagementApi.md#createWorkspace) | **POST** /public/v1/workspaces | Create Workspace


# **addMember**
> AddMemberResponse addMember(addMemberRequest)

### Example


```typescript
import * as pd_api from 'pandadoc-node-client';

// replace it with your API key
const API_KEY = "YOUR_API_KEY";
const configuration = pd_api.createConfiguration(
{ authMethods: {apiKey: `API-Key ${API_KEY}`} }
);
const apiInstance = new pd_api.UserAndWorkspaceManagementApi(configuration);

const body:pd_api.UserAndWorkspaceManagementApiAddMemberRequest = {
// string
workspaceId: "BhVzRcxH9Z2LgfPPGXFUBa",
// AddMemberRequest
addMemberRequest: {
userId: "2eWSKSvVqmuVCnuUK3iWwD",
role: "Admin",
},
// boolean | Send a confirmation email to the user that was added to workspace(s). (optional)
notifyUser: true,
// boolean | Send a confirmation email to all workspace admins indicating that the user has been added to the workspace. (optional)
notifyWsAdmins: true,
};

apiInstance.addMember(body).then((data) => {
console.log('API called successfully. Returned data: %o', data);
}).catch((error) => console.error(error));
```


### Parameters

Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**addMemberRequest** | **AddMemberRequest**| |
**workspaceId** | [**string**] | | defaults to undefined
**notifyUser** | [**boolean**] | Send a confirmation email to the user that was added to workspace(s). | (optional) defaults to undefined
**notifyWsAdmins** | [**boolean**] | Send a confirmation email to all workspace admins indicating that the user has been added to the workspace. | (optional) defaults to undefined


### Return type

**AddMemberResponse**

### Authorization

[apiKey](../README.md#apiKey), [oauth2](../README.md#oauth2)

### HTTP request headers

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


### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
**201** | OK | - |
**400** | Bad Request | - |
**401** | Authentication error | - |
**403** | Permission error | - |
**404** | Not found | - |
**429** | Too Many Requests | - |

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

# **createUser**
> CreateUserResponse createUser(createUserRequest)

### Example


```typescript
import * as pd_api from 'pandadoc-node-client';

// replace it with your API key
const API_KEY = "YOUR_API_KEY";
const configuration = pd_api.createConfiguration(
{ authMethods: {apiKey: `API-Key ${API_KEY}`} }
);
const apiInstance = new pd_api.UserAndWorkspaceManagementApi(configuration);

const body:pd_api.UserAndWorkspaceManagementApiCreateUserRequest = {
// CreateUserRequest
createUserRequest: {
user: {
email: "[email protected]",
firstName: "John",
lastName: "Doe",
phoneNumber: "+14842634627",
},
workspaces: [
{
workspaceId: "2eWSKSvVqmuVCnuUK3iWwD",
role: "Admin",
},
],
license: "Full",
},
// boolean | Send a confirmation email to the user that was added to workspace(s). (optional)
notifyUser: true,
// boolean | Send a confirmation email to all workspace admins indicating that the user has been added to the workspace. (optional)
notifyWsAdmins: true,
};

apiInstance.createUser(body).then((data) => {
console.log('API called successfully. Returned data: %o', data);
}).catch((error) => console.error(error));
```


### Parameters

Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**createUserRequest** | **CreateUserRequest**| |
**notifyUser** | [**boolean**] | Send a confirmation email to the user that was added to workspace(s). | (optional) defaults to undefined
**notifyWsAdmins** | [**boolean**] | Send a confirmation email to all workspace admins indicating that the user has been added to the workspace. | (optional) defaults to undefined


### Return type

**CreateUserResponse**

### Authorization

[apiKey](../README.md#apiKey), [oauth2](../README.md#oauth2)

### HTTP request headers

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


### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
**201** | OK | - |
**400** | Bad Request | - |
**401** | Authentication error | - |
**403** | Permission error | - |
**404** | Not found | - |
**429** | Too Many Requests | - |

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

# **createWorkspace**
> CreateWorkspaceResponse createWorkspace(createWorkspaceRequest)

### Example


```typescript
import * as pd_api from 'pandadoc-node-client';

// replace it with your API key
const API_KEY = "YOUR_API_KEY";
const configuration = pd_api.createConfiguration(
{ authMethods: {apiKey: `API-Key ${API_KEY}`} }
);
const apiInstance = new pd_api.UserAndWorkspaceManagementApi(configuration);

const body:pd_api.UserAndWorkspaceManagementApiCreateWorkspaceRequest = {
// CreateWorkspaceRequest
createWorkspaceRequest: {
name: "A new workspace",
},
};

apiInstance.createWorkspace(body).then((data) => {
console.log('API called successfully. Returned data: %o', data);
}).catch((error) => console.error(error));
```


### Parameters

Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**createWorkspaceRequest** | **CreateWorkspaceRequest**| |


### Return type

**CreateWorkspaceResponse**

### Authorization

[apiKey](../README.md#apiKey), [oauth2](../README.md#oauth2)

### HTTP request headers

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


### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
**201** | OK | - |
**401** | Authentication error | - |
**403** | Permission error | - |
**404** | Not found | - |
**429** | Too Many Requests | - |

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

Loading

0 comments on commit dcfc338

Please sign in to comment.