API documentation

Discover how to connect your processes to the Outwork network.

Overview

The API gives you the ability to register partners in Outwork.com directly from your own website. Once a new partner submits the form, a new instance will be created in the platform and a connect request will be sent to your organization’s instance.

First Steps

Authentication

Authentication to the API is performed via Basic Auth. You only have to provide your API key as the authorization header in the requests.

OUTWORK-TOKEN application_token="bnVsbA:1a1BIT:vR2XtYoqxPxiym-C3zrF8Yw0YAkx"

The API settings are available under the Integrations section of your Outwork.com instance. You can enable/disable the endpoint and reset the API key whenever you want.

Endpoints

Every premium instance has an endpoint available for registering partners:

https://your-tenant-domain.outwork.com/api/apply/

And another endpoint for fetching the list of the partner types created in that instance. Custom partner types can be created in the Settings section of your Outwork.com instance.

https://your-tenant-domain.outwork.com/api/partner_type/

Requests

Retrieving the partner types list, only GET method is allowed. Creating new partners, the request method must be POST. Data must be passed in JSON and the following parameters are required.

  • organization_name. Partner’s company name (e.g. Doe Inc.)
  • organization_domain. Partner’s company domain (e.g. example.com)
  • first_name. Partner’s contact first name (e.g. John)
  • last_name. Partner’s contact last name (e.g. Doe)
  • email. Partner’s contact email address (e.g. jdoe@example.com)

There are optional fields for partner type and text comment.

  • partner_type. Partner type for the applicant using the name value of the partner type object.
  • comment. Partner application text message (optional).

Also, any additional text field that you would like to include in your partner application form can be submitted directly to the API. Those fields will appear in the Additional Information section of the connect request in Outwork.com.

Response

The API gives different response codes depending on the result of the request.

  • 200 - Success.
  • 403 - Authorization failed. The API key is not valid.
  • 400 - Bad request. The response contains a JSON object with the errors.

Examples

Partner Types Endpoint: Request

The following example shows the format of a GET request for fetching the list of partner types.

curl -H 'Authorization: OUTWORK-TOKEN application_token="XX:XXXXX:XXXXXXXXXX"' \
'https://acme.outwork.com/api/partner_type/'

Partner Types Endpoint: Responses

These are the possible responses depending on the result of the request.

HTTP 403
{"detail": "Authentication credentials were not provided."}

HTTP 200
[
  {"id": "1", "name": "Default"},
  {"id": "2", "name": "Tech Partner"}
]

Partner Application Endpoint: Request

The following example shows the format of a POST request for registering a new partner called Doe, Inc. in the Acme’s instance.

curl -H 'Authorization: OUTWORK-TOKEN application_token="XX:XXXXX:XXXXXXXXXX"' \
-d '{
"organization_name": "Doe, Inc.",
"first_name": "john",
"last_name": "doe",
"email": "jdoe@example.com",
"organization_domain": "example.com",
"partner_type": "Tech Partner"
}' \
'https://acme.outwork.com/api/apply/'

Partner Application Endpoint: Responses

These are the possible responses depending on the result of the request.

HTTP 403
{"detail": "Authentication credentials were not provided."}

HTTP 400
{
"organization_name": ["This organization is already registered"],
"organization_domain": ["This organization is already registered"]
}

HTTP 200
{}