Skip to content

Latest commit

 

History

History
301 lines (202 loc) · 9.63 KB

ContactsApi.md

File metadata and controls

301 lines (202 loc) · 9.63 KB

OpenAPI\Client\ContactsApi

All URIs are relative to https://openapi.flowaccount.com/v1

Method HTTP request Description
contactsGet GET /contacts Get list all contacts.
contactsIdDelete DELETE /contacts/{id} Delete contacts.
contactsIdGet GET /contacts/{id} Get contacts.
contactsIdPut PUT /contacts/{id} Update contacts.
contactsPost POST /contacts Create contacts

contactsGet

\OpenAPI\Client\Model\ContactResponse contactsGet($authorization, $current_page, $page_size, $sort_by, $filter)

Get list all contacts.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');


$apiInstance = new OpenAPI\Client\Api\ContactsApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client()
);
$authorization = 'Bearer accessToken'; // string | 
$current_page = 56; // int | Query current page contacts. <br>Example Pattern: <ex>/contacts?currentPage=1 </ex><ex>/contacts?currentPage=1&pageSize=20</ex>
$page_size = 56; // int | Query contacts list amount per page. <br>Example Pattern: <ex> /contacts?pageSize=20 </ex>
$sort_by = 'sort_by_example'; // string | Contact Sort By Example Pattern:<br> namelocal = Sort By Contact Name <br> contactPerson = Sort By Contact Person <br> email = Sort By Email <br> phone2 = Sort By Contact Mobile <br> contactType = Sort By Contact Type <ex> /contacts?sortBy=[{'name':'contactPerson','sortOrder':'desc'}]</ex>
$filter = 'filter_example'; // string | Contact Filter Example Pattern: <ex> /contacts?filter=[{'columnName':'contactType','columnValue':'3','columnPredicateOperator':'And'}]</ex>

try {
    $result = $apiInstance->contactsGet($authorization, $current_page, $page_size, $sort_by, $filter);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ContactsApi->contactsGet: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
authorization string [default to 'Bearer accessToken']
current_page int Query current page contacts. <br>Example Pattern: <ex>/contacts?currentPage=1 </ex><ex>/contacts?currentPage=1&pageSize=20</ex> [optional]
page_size int Query contacts list amount per page. <br>Example Pattern: <ex> /contacts?pageSize=20 </ex> [optional]
sort_by string Contact Sort By Example Pattern:<br> namelocal = Sort By Contact Name <br> contactPerson = Sort By Contact Person <br> email = Sort By Email <br> phone2 = Sort By Contact Mobile <br> contactType = Sort By Contact Type <ex> /contacts?sortBy=[{'name':'contactPerson','sortOrder':'desc'}]</ex> [optional]
filter string Contact Filter Example Pattern: <ex> /contacts?filter=[{'columnName':'contactType','columnValue':'3','columnPredicateOperator':'And'}]</ex> [optional]

Return type

\OpenAPI\Client\Model\ContactResponse

Authorization

No authorization required

HTTP request headers

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

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

contactsIdDelete

\OpenAPI\Client\Model\DeleteResponse contactsIdDelete($authorization, $id)

Delete contacts.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');


$apiInstance = new OpenAPI\Client\Api\ContactsApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client()
);
$authorization = 'Bearer accessToken'; // string | 
$id = 'id_example'; // string | เลข Id Contact

try {
    $result = $apiInstance->contactsIdDelete($authorization, $id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ContactsApi->contactsIdDelete: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
authorization string [default to 'Bearer accessToken']
id string เลข Id Contact

Return type

\OpenAPI\Client\Model\DeleteResponse

Authorization

No authorization required

HTTP request headers

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

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

contactsIdGet

\OpenAPI\Client\Model\ContactResponse contactsIdGet($authorization, $id)

Get contacts.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');


$apiInstance = new OpenAPI\Client\Api\ContactsApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client()
);
$authorization = 'Bearer accessToken'; // string | 
$id = 'id_example'; // string | เลข Id Contact

try {
    $result = $apiInstance->contactsIdGet($authorization, $id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ContactsApi->contactsIdGet: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
authorization string [default to 'Bearer accessToken']
id string เลข Id Contact

Return type

\OpenAPI\Client\Model\ContactResponse

Authorization

No authorization required

HTTP request headers

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

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

contactsIdPut

\OpenAPI\Client\Model\ContactResponse contactsIdPut($authorization, $id, $contact)

Update contacts.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');


$apiInstance = new OpenAPI\Client\Api\ContactsApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client()
);
$authorization = 'Bearer accessToken'; // string | 
$id = 'id_example'; // string | เลข Id Contact
$contact = new \OpenAPI\Client\Model\Contact(); // \OpenAPI\Client\Model\Contact | 

try {
    $result = $apiInstance->contactsIdPut($authorization, $id, $contact);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ContactsApi->contactsIdPut: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
authorization string [default to 'Bearer accessToken']
id string เลข Id Contact
contact \OpenAPI\Client\Model\Contact

Return type

\OpenAPI\Client\Model\ContactResponse

Authorization

No authorization required

HTTP request headers

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

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

contactsPost

\OpenAPI\Client\Model\ContactResponse contactsPost($authorization, $contact)

Create contacts

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');


$apiInstance = new OpenAPI\Client\Api\ContactsApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client()
);
$authorization = 'Bearer accessToken'; // string | 
$contact = new \OpenAPI\Client\Model\Contact(); // \OpenAPI\Client\Model\Contact | 

try {
    $result = $apiInstance->contactsPost($authorization, $contact);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ContactsApi->contactsPost: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
authorization string [default to 'Bearer accessToken']
contact \OpenAPI\Client\Model\Contact

Return type

\OpenAPI\Client\Model\ContactResponse

Authorization

No authorization required

HTTP request headers

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

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