Definition of the Wrike API 3.0.
This PHP package is automatically generated by the Swagger Codegen project:
- API version: 1.1.0
- Build package: io.swagger.codegen.languages.PhpClientCodegen
PHP 5.4.0 and later
To install the bindings via Composer, add the following to composer.json
:
{
"repositories": [
{
"type": "git",
"url": "https://github.com/capKopper/Wrike-API.git"
}
],
"require": {
"capKopper/Wrike-API": "*@dev"
}
}
Then run composer install
Download the files and include autoload.php
:
require_once('/path/to/wrike-php-client/autoload.php');
To run the unit tests:
composer install
./vendor/bin/phpunit
Please follow the installation procedure and then run the following:
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure OAuth2 access token for authorization: oauth
Wrike\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure API key authorization: token
Wrike\Client\Configuration::getDefaultConfiguration()->setApiKey('Authorization', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// Wrike\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('Authorization', 'Bearer');
$api_instance = new Wrike\Client\Api\DefaultApi();
$me = true; // bool | If present - only contact info of requesting user is returned
$metadata = "metadata_example"; // string | Metadata filter, exact match for metadata key or key-value pair
$fields = "fields_example"; // string | Json string array of optional fields to be included in the response model
try {
$result = $api_instance->getContacts($me, $metadata, $fields);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling DefaultApi->getContacts: ', $e->getMessage(), PHP_EOL;
}
?>
All URIs are relative to https://www.wrike.com/api/v3
Class | Method | HTTP request | Description |
---|---|---|---|
DefaultApi | getContacts | GET /contacts | |
DefaultApi | getContactsById | GET /contacts/{contactId} | |
DefaultApi | getFolders | GET /folders | |
DefaultApi | getFoldersFromFolderId | GET /folders/{folderId}/folders | |
DefaultApi | getTasks | GET /tasks | |
DefaultApi | getTasksById | GET /tasks/{taskId} | |
DefaultApi | getTimelogs | GET /timelogs | |
DefaultApi | getTimelogsForAccount | GET /accounts/{accountId}/timelogs | |
DefaultApi | getTimelogsForContact | GET /contacts/{contactId}/timelogs | |
DefaultApi | getTimelogsForFolder | GET /folders/{folderId}/timelogs | |
DefaultApi | getTimelogsForTask | GET /tasks/{taskId}/timelogs | |
DefaultApi | updateMyContact | PUT /contacts/{contactId} |
- Contact
- CustomField
- Dates
- Error
- Folder
- InlineResponse200
- InlineResponse2001
- InlineResponse2002
- InlineResponse2003
- Metadata
- Profile
- Project
- Task
- Timelog
- Type: OAuth
- Flow: accessCode
- Authorization URL: https://www.wrike.com/oauth2/authorize?client_id={client_id}&response_type=code&redirect_uri={redirect_uri}
- Scopes:
- basic: to read any and all data related to Wrike
- Type: API key
- API key parameter name: Authorization
- Location: HTTP header