Skip to content

Commit c0739de

Browse files
authored
Merge pull request #22 from PandaDoc/v6.2.0
v6.2.0
2 parents ad97ea3 + 068d21d commit c0739de

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

45 files changed

+6847
-110
lines changed

README.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ or add the following to `composer.json`:
1919
```json
2020
{
2121
"require": {
22-
"pandadoc/php-client": "6.1.0"
22+
"pandadoc/php-client": "6.2.0"
2323
}
2424
}
2525
```
@@ -97,7 +97,7 @@ Class | Method | HTTP request | Description
9797
*DocumentAttachmentsApi* | [**listDocumentAttachments**](docs/Api/DocumentAttachmentsApi.md#listdocumentattachments) | **GET** /public/v1/documents/{id}/attachments | Document Attachment List
9898
*DocumentRecipientsApi* | [**addDocumentRecipient**](docs/Api/DocumentRecipientsApi.md#adddocumentrecipient) | **POST** /public/v1/documents/{id}/recipients | Add Document Recipient
9999
*DocumentRecipientsApi* | [**deleteDocumentRecipient**](docs/Api/DocumentRecipientsApi.md#deletedocumentrecipient) | **DELETE** /public/v1/documents/{id}/recipients/{recipient_id} | Delete Document Recipient
100-
*DocumentRecipientsApi* | [**editDocumentRecipient**](docs/Api/DocumentRecipientsApi.md#editdocumentrecipient) | **PATCH** /public/v1/documents/{id}/recipients/{recipient_id} | Edit Document Recipient
100+
*DocumentRecipientsApi* | [**editDocumentRecipient**](docs/Api/DocumentRecipientsApi.md#editdocumentrecipient) | **PATCH** /public/v1/documents/{id}/recipients/recipient/{recipient_id} | Edit Document Recipient
101101
*DocumentRecipientsApi* | [**reassignDocumentRecipient**](docs/Api/DocumentRecipientsApi.md#reassigndocumentrecipient) | **POST** /public/v1/documents/{id}/recipients/{recipient_id}/reassign | Reassign Document Recipient
102102
*DocumentsApi* | [**changeDocumentStatus**](docs/Api/DocumentsApi.md#changedocumentstatus) | **PATCH** /public/v1/documents/{id}/status | Document status change
103103
*DocumentsApi* | [**createDocument**](docs/Api/DocumentsApi.md#createdocument) | **POST** /public/v1/documents | Create document
@@ -135,6 +135,9 @@ Class | Method | HTTP request | Description
135135
*TemplatesApi* | [**deleteTemplate**](docs/Api/TemplatesApi.md#deletetemplate) | **DELETE** /public/v1/templates/{id} | Delete Template
136136
*TemplatesApi* | [**detailsTemplate**](docs/Api/TemplatesApi.md#detailstemplate) | **GET** /public/v1/templates/{id}/details | Details Template
137137
*TemplatesApi* | [**listTemplates**](docs/Api/TemplatesApi.md#listtemplates) | **GET** /public/v1/templates | List Templates
138+
*UserAndWorkspaceManagementApi* | [**addMember**](docs/Api/UserAndWorkspaceManagementApi.md#addmember) | **POST** /public/v1/workspaces/{workspace_id}/members | Add member
139+
*UserAndWorkspaceManagementApi* | [**createUser**](docs/Api/UserAndWorkspaceManagementApi.md#createuser) | **POST** /public/v1/users | Create User
140+
*UserAndWorkspaceManagementApi* | [**createWorkspace**](docs/Api/UserAndWorkspaceManagementApi.md#createworkspace) | **POST** /public/v1/workspaces | Create Workspace
138141
*WebhookEventsApi* | [**detailsWebhookEvent**](docs/Api/WebhookEventsApi.md#detailswebhookevent) | **GET** /public/v1/webhook-events/{id} | Get webhook event by uuid
139142
*WebhookEventsApi* | [**listWebhookEvent**](docs/Api/WebhookEventsApi.md#listwebhookevent) | **GET** /public/v1/webhook-events | Get webhook event page
140143
*WebhookSubscriptionsApi* | [**createWebhookSubscription**](docs/Api/WebhookSubscriptionsApi.md#createwebhooksubscription) | **POST** /public/v1/webhook-subscriptions | Create webhook subscription

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "pandadoc/php-client",
3-
"version": "6.1.0",
3+
"version": "6.2.0",
44
"description": "The Official PandaDoc PHP client SDK",
55
"keywords": [
66
"openapi",

docs/Api/DocumentRecipientsApi.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Method | HTTP request | Description
66
------------- | ------------- | -------------
77
[**addDocumentRecipient()**](DocumentRecipientsApi.md#addDocumentRecipient) | **POST** /public/v1/documents/{id}/recipients | Add Document Recipient
88
[**deleteDocumentRecipient()**](DocumentRecipientsApi.md#deleteDocumentRecipient) | **DELETE** /public/v1/documents/{id}/recipients/{recipient_id} | Delete Document Recipient
9-
[**editDocumentRecipient()**](DocumentRecipientsApi.md#editDocumentRecipient) | **PATCH** /public/v1/documents/{id}/recipients/{recipient_id} | Edit Document Recipient
9+
[**editDocumentRecipient()**](DocumentRecipientsApi.md#editDocumentRecipient) | **PATCH** /public/v1/documents/{id}/recipients/recipient/{recipient_id} | Edit Document Recipient
1010
[**reassignDocumentRecipient()**](DocumentRecipientsApi.md#reassignDocumentRecipient) | **POST** /public/v1/documents/{id}/recipients/{recipient_id}/reassign | Reassign Document Recipient
1111

1212

docs/Api/SectionsApi.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ Name | Type | Description | Notes
203203
## `uploadSection()`
204204

205205
```php
206-
uploadSection($documentId, $uploadSectionRequest): \PandaDoc\Client\Model\UploadSectionResponse
206+
uploadSection($documentId, $uploadSectionRequest, $mergeFieldScope): \PandaDoc\Client\Model\UploadSectionResponse
207207
```
208208

209209
Upload section
@@ -232,9 +232,10 @@ $apiInstance = new PandaDoc\Client\Api\SectionsApi(
232232
);
233233
$documentId = BhVzRcxH9Z2LgfPPGXFUBa; // string | Document ID
234234
$uploadSectionRequest = {"template_uuid":"hryJY9mqYZHjQCYQuSjRQg","recipients":[{"email":"[email protected]","first_name":"Josh","last_name":"Ron","role":"user"}],"fields":{"Favorite.Color":{"value":"PandaDoc green"},"Delivery":{"value":"Same Day Delivery"},"Like":{"value":true},"Date":{"value":"2019-12-31T00:00:00.000Z"}},"pricing_tables":[{"name":"Pricing Table 1","data_merge":true,"options":{"Tax":{"type":"percent","name":"Tax","value":10}},"sections":[{"title":"Sample Section","default":true,"rows":[{"options":{"optional":true,"optional_selected":true,"qty_editable":true},"data":{"Name":"Toy Panda","Description":"Fluffy!","Price":10,"QTY":3,"Tax":{"value":20,"type":"percent"}},"custom_fields":{"Fluffiness":"5 / 5"}}]}]}],"content_placeholders":[{"block_id":"{block_id}","content_library_items":[{"id":"{cli_id}","pricing_tables":[{"name":"Pricing Table 1","data_merge":false,"options":{"discount":{"type":"absolute","name":"Discount","value":2.26}},"sections":[{"title":"Sample Section","default":true,"rows":[{"options":{"optional":true,"optional_selected":true,"qty_editable":true},"data":{"name":"Placeholder Panda","price":10,"qty":3}}]}]}]},{"id":"{cli_id_2}","recipients":[{"email":"[email protected]","first_name":"John","last_name":"Roe","role":"Signer","signing_order":2}],"fields":{"Date":{"value":"2019-12-31T00:00:00.000Z"}}}]}]}; // \PandaDoc\Client\Model\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)
235+
$mergeFieldScope = 'mergeFieldScope_example'; // string | 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.
235236

236237
try {
237-
$result = $apiInstance->uploadSection($documentId, $uploadSectionRequest);
238+
$result = $apiInstance->uploadSection($documentId, $uploadSectionRequest, $mergeFieldScope);
238239
print_r($result);
239240
} catch (Exception $e) {
240241
echo 'Exception when calling SectionsApi->uploadSection: ', $e->getMessage(), PHP_EOL;
@@ -247,6 +248,7 @@ Name | Type | Description | Notes
247248
------------- | ------------- | ------------- | -------------
248249
**documentId** | **string**| Document ID |
249250
**uploadSectionRequest** | [**\PandaDoc\Client\Model\UploadSectionRequest**](../Model/UploadSectionRequest.md)| 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) |
251+
**mergeFieldScope** | **string**| 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]
250252

251253
### Return type
252254

Lines changed: 206 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,206 @@
1+
# PandaDoc\Client\UserAndWorkspaceManagementApi
2+
3+
All URIs are relative to https://api.pandadoc.com.
4+
5+
Method | HTTP request | Description
6+
------------- | ------------- | -------------
7+
[**addMember()**](UserAndWorkspaceManagementApi.md#addMember) | **POST** /public/v1/workspaces/{workspace_id}/members | Add member
8+
[**createUser()**](UserAndWorkspaceManagementApi.md#createUser) | **POST** /public/v1/users | Create User
9+
[**createWorkspace()**](UserAndWorkspaceManagementApi.md#createWorkspace) | **POST** /public/v1/workspaces | Create Workspace
10+
11+
12+
## `addMember()`
13+
14+
```php
15+
addMember($workspaceId, $addMemberRequest, $notifyUser, $notifyWsAdmins): \PandaDoc\Client\Model\AddMemberResponse
16+
```
17+
18+
Add member
19+
20+
### Example
21+
22+
```php
23+
<?php
24+
require_once(__DIR__ . '/vendor/autoload.php');
25+
26+
27+
// Configure API key authorization: apiKey
28+
$config = PandaDoc\Client\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'YOUR_API_KEY');
29+
// Setup prefix (e.g. Bearer) for API key, if needed
30+
$config = PandaDoc\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'API-Key');
31+
32+
// Configure OAuth2 access token for authorization: oauth2
33+
// $config = PandaDoc\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
34+
35+
36+
$apiInstance = new PandaDoc\Client\Api\UserAndWorkspaceManagementApi(
37+
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
38+
// This is optional, `GuzzleHttp\Client` will be used as default.
39+
new GuzzleHttp\Client(),
40+
$config
41+
);
42+
$workspaceId = BhVzRcxH9Z2LgfPPGXFUBa; // string
43+
$addMemberRequest = new \PandaDoc\Client\Model\AddMemberRequest(); // \PandaDoc\Client\Model\AddMemberRequest
44+
$notifyUser = True; // bool | Send a confirmation email to the user that was added to workspace(s).
45+
$notifyWsAdmins = True; // bool | Send a confirmation email to all workspace admins indicating that the user has been added to the workspace.
46+
47+
try {
48+
$result = $apiInstance->addMember($workspaceId, $addMemberRequest, $notifyUser, $notifyWsAdmins);
49+
print_r($result);
50+
} catch (Exception $e) {
51+
echo 'Exception when calling UserAndWorkspaceManagementApi->addMember: ', $e->getMessage(), PHP_EOL;
52+
}
53+
```
54+
55+
### Parameters
56+
57+
Name | Type | Description | Notes
58+
------------- | ------------- | ------------- | -------------
59+
**workspaceId** | **string**| |
60+
**addMemberRequest** | [**\PandaDoc\Client\Model\AddMemberRequest**](../Model/AddMemberRequest.md)| |
61+
**notifyUser** | **bool**| Send a confirmation email to the user that was added to workspace(s). | [optional]
62+
**notifyWsAdmins** | **bool**| Send a confirmation email to all workspace admins indicating that the user has been added to the workspace. | [optional]
63+
64+
### Return type
65+
66+
[**\PandaDoc\Client\Model\AddMemberResponse**](../Model/AddMemberResponse.md)
67+
68+
### Authorization
69+
70+
[apiKey](../../README.md#apiKey), [oauth2](../../README.md#oauth2)
71+
72+
### HTTP request headers
73+
74+
- **Content-Type**: `application/json`
75+
- **Accept**: `application/json`
76+
77+
[[Back to top]](#) [[Back to API list]](../../README.md#endpoints)
78+
[[Back to README]](../../README.md)
79+
80+
## `createUser()`
81+
82+
```php
83+
createUser($createUserRequest, $notifyUser, $notifyWsAdmins): \PandaDoc\Client\Model\CreateUserResponse
84+
```
85+
86+
Create User
87+
88+
### Example
89+
90+
```php
91+
<?php
92+
require_once(__DIR__ . '/vendor/autoload.php');
93+
94+
95+
// Configure API key authorization: apiKey
96+
$config = PandaDoc\Client\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'YOUR_API_KEY');
97+
// Setup prefix (e.g. Bearer) for API key, if needed
98+
$config = PandaDoc\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'API-Key');
99+
100+
// Configure OAuth2 access token for authorization: oauth2
101+
// $config = PandaDoc\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
102+
103+
104+
$apiInstance = new PandaDoc\Client\Api\UserAndWorkspaceManagementApi(
105+
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
106+
// This is optional, `GuzzleHttp\Client` will be used as default.
107+
new GuzzleHttp\Client(),
108+
$config
109+
);
110+
$createUserRequest = new \PandaDoc\Client\Model\CreateUserRequest(); // \PandaDoc\Client\Model\CreateUserRequest
111+
$notifyUser = True; // bool | Send a confirmation email to the user that was added to workspace(s).
112+
$notifyWsAdmins = True; // bool | Send a confirmation email to all workspace admins indicating that the user has been added to the workspace.
113+
114+
try {
115+
$result = $apiInstance->createUser($createUserRequest, $notifyUser, $notifyWsAdmins);
116+
print_r($result);
117+
} catch (Exception $e) {
118+
echo 'Exception when calling UserAndWorkspaceManagementApi->createUser: ', $e->getMessage(), PHP_EOL;
119+
}
120+
```
121+
122+
### Parameters
123+
124+
Name | Type | Description | Notes
125+
------------- | ------------- | ------------- | -------------
126+
**createUserRequest** | [**\PandaDoc\Client\Model\CreateUserRequest**](../Model/CreateUserRequest.md)| |
127+
**notifyUser** | **bool**| Send a confirmation email to the user that was added to workspace(s). | [optional]
128+
**notifyWsAdmins** | **bool**| Send a confirmation email to all workspace admins indicating that the user has been added to the workspace. | [optional]
129+
130+
### Return type
131+
132+
[**\PandaDoc\Client\Model\CreateUserResponse**](../Model/CreateUserResponse.md)
133+
134+
### Authorization
135+
136+
[apiKey](../../README.md#apiKey), [oauth2](../../README.md#oauth2)
137+
138+
### HTTP request headers
139+
140+
- **Content-Type**: `application/json`
141+
- **Accept**: `application/json`
142+
143+
[[Back to top]](#) [[Back to API list]](../../README.md#endpoints)
144+
[[Back to README]](../../README.md)
145+
146+
## `createWorkspace()`
147+
148+
```php
149+
createWorkspace($createWorkspaceRequest): \PandaDoc\Client\Model\CreateWorkspaceResponse
150+
```
151+
152+
Create Workspace
153+
154+
### Example
155+
156+
```php
157+
<?php
158+
require_once(__DIR__ . '/vendor/autoload.php');
159+
160+
161+
// Configure API key authorization: apiKey
162+
$config = PandaDoc\Client\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'YOUR_API_KEY');
163+
// Setup prefix (e.g. Bearer) for API key, if needed
164+
$config = PandaDoc\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'API-Key');
165+
166+
// Configure OAuth2 access token for authorization: oauth2
167+
// $config = PandaDoc\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
168+
169+
170+
$apiInstance = new PandaDoc\Client\Api\UserAndWorkspaceManagementApi(
171+
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
172+
// This is optional, `GuzzleHttp\Client` will be used as default.
173+
new GuzzleHttp\Client(),
174+
$config
175+
);
176+
$createWorkspaceRequest = new \PandaDoc\Client\Model\CreateWorkspaceRequest(); // \PandaDoc\Client\Model\CreateWorkspaceRequest
177+
178+
try {
179+
$result = $apiInstance->createWorkspace($createWorkspaceRequest);
180+
print_r($result);
181+
} catch (Exception $e) {
182+
echo 'Exception when calling UserAndWorkspaceManagementApi->createWorkspace: ', $e->getMessage(), PHP_EOL;
183+
}
184+
```
185+
186+
### Parameters
187+
188+
Name | Type | Description | Notes
189+
------------- | ------------- | ------------- | -------------
190+
**createWorkspaceRequest** | [**\PandaDoc\Client\Model\CreateWorkspaceRequest**](../Model/CreateWorkspaceRequest.md)| |
191+
192+
### Return type
193+
194+
[**\PandaDoc\Client\Model\CreateWorkspaceResponse**](../Model/CreateWorkspaceResponse.md)
195+
196+
### Authorization
197+
198+
[apiKey](../../README.md#apiKey), [oauth2](../../README.md#oauth2)
199+
200+
### HTTP request headers
201+
202+
- **Content-Type**: `application/json`
203+
- **Accept**: `application/json`
204+
205+
[[Back to top]](#) [[Back to API list]](../../README.md#endpoints)
206+
[[Back to README]](../../README.md)

docs/Model/AddMemberRequest.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# # AddMemberRequest
2+
3+
## Properties
4+
5+
Name | Type | Description | Notes
6+
------------ | ------------- | ------------- | -------------
7+
**userId** | **string** | |
8+
**role** | **string** | |
9+
10+
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)

docs/Model/AddMemberResponse.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# # AddMemberResponse
2+
3+
## Properties
4+
5+
Name | Type | Description | Notes
6+
------------ | ------------- | ------------- | -------------
7+
**memberId** | **string** | | [optional]
8+
**workspaceId** | **string** | | [optional]
9+
**role** | **string** | | [optional]
10+
**email** | **string** | | [optional]
11+
**firstName** | **string** | | [optional]
12+
**lastName** | **string** | | [optional]
13+
14+
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)

docs/Model/ContactCreateRequest.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
Name | Type | Description | Notes
66
------------ | ------------- | ------------- | -------------
7-
**email** | **string** | |
7+
**email** | **string** | | [optional]
88
**firstName** | **string** | | [optional]
99
**lastName** | **string** | | [optional]
1010
**company** | **string** | | [optional]

docs/Model/CreateUserRequest.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# # CreateUserRequest
2+
3+
## Properties
4+
5+
Name | Type | Description | Notes
6+
------------ | ------------- | ------------- | -------------
7+
**user** | [**\PandaDoc\Client\Model\CreateUserRequestUser**](CreateUserRequestUser.md) | |
8+
**workspaces** | [**\PandaDoc\Client\Model\CreateUserRequestWorkspaces[]**](CreateUserRequestWorkspaces.md) | Info for adding a user to a workspace(s) |
9+
**license** | **string** | |
10+
11+
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)

docs/Model/CreateUserRequestUser.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# # CreateUserRequestUser
2+
3+
## Properties
4+
5+
Name | Type | Description | Notes
6+
------------ | ------------- | ------------- | -------------
7+
**email** | **string** | | [optional]
8+
**firstName** | **string** | | [optional]
9+
**lastName** | **string** | | [optional]
10+
**phoneNumber** | **string** | | [optional]
11+
12+
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)

0 commit comments

Comments
 (0)