Try Free for 14 DaysRequest A Demo

API Documentation - Accounts

The accounts resource allows you to retrieve, edit, add, and delete accounts.

Accounts Instance Resources

Method Endpoint Description
GET /api/v1/accounts Get a paginated list of details for all accounts.
GET /api/v1/accounts/{account_id} Get details about a single account.
POST /api/v1/accounts Create a new account.
POST /api/v1/accounts/{account_id} Edit details for a single account.
DELETE /api/v1/accounts/{account_id} Delete a single account.

Get All Accounts

Get a paginated list of details for all accounts.

Resource Details

Method Endpoint
GET https://app.whatconverts.com/api/v1/accounts

Supported Parameters

Parameter Type Description Required
accounts_per_page number Number of accounts to return for this request (default 25, maximum 250). No
page_number number Page number to return for this request. No
start_date string Start date for this request in date or date/time ISO 8601 format (UTC); 2015-11-10 or 2015-11-10T00:00:00Z. No
end_date string End date for this request in date or date/time ISO 8601 format (UTC); 2015-11-10 or 2015-11-10T00:00:00Z. No
order string Order in which to return the accounts by date created; asc or (default) desc. No

Response Details

Parameter Type Description
accounts_per_page number The number of accounts returned in the request.
page_number number The current page number in the request.
total_pages number The total amount of pages available in the request.
total_accounts number The total amount of accounts available in the request.
accounts array Contains all the requested accounts.
account_id number Unique identifier for the account.
account_name string The name of the account.
date_created string Date and time when the account was created in ISO 8601 format (UTC).
profiles array Contains all the profiles under within the requested accounts.
profile_id number Unique identifier for the profile.
profile_name string The name of the profile.
date_created string Date and time when the profile was created in ISO 8601 format (UTC).

Example Response

    {
      "page_number": 1,
      "accounts_per_page": 25,
      "total_pages": 2,
      "total_accounts": 45,
      "accounts": [
        {
          "account_id": 5411295,
          "account_name": "WhatConverts",
          "date_created": "2016-06-24T17:24:42Z",
          "profiles": [ 
            {
              "profile_id": 2548713,
              "profile_name": "WhatConverts Tracking",
              "date_created": "2016-06-24T17:24:42Z"
            },
            ...
          ]
        },
        ...
      ]
    }
    

Get Single Account

Get details for specific account.

Resource Details

Method Endpoint
GET https://app.whatconverts.com/api/v1/accounts/{account_id}

Supported Parameters

No supported parameters.

Response Details

Includes all response details from get all accounts resource.

Create New Account

Create a new account.

Resource Details

Method Endpoint
POST https://app.whatconverts.com/api/v1/accounts

Supported Parameters

Parameter Type Description Required
account_name string The name for this account. Yes
create_profile boolean Create a profile with the same name as the account; (default) true or false. No

Response Details

Parameter Type Description
account_id number Unique identifier for the account.
account_name string The name of the account.
date_created string Date and time when the account was created in ISO 8601 format (UTC).
profiles array Contains all the profiles under within the requested accounts.
profile_id number Unique identifier for the profile.
profile_name string The name of the profile.
date_created string Date and time when the profile was created in ISO 8601 format (UTC).

Example Response

    {
      "account_id": 5411295,
      "account_name": "WhatConverts",
      "date_created": "2016-06-24T17:24:42Z",
      "profiles": [ 
        {
          "profile_id": 2548713,
          "profile_name": "WhatConverts",
          "date_created": "2016-06-24T17:24:42Z"
        }
      ]
    }
    

Edit Account

Edit details for a single account.

Resource Details

Method Endpoint
POST https://app.whatconverts.com/api/v1/accounts/{account_id}

Supported Parameters

Parameter Type Description Required
account_name string The name for this account. Yes

Response Details

Parameter Type Description
account_id number Unique identifier for the account.
account_name string The name of the account.
date_created string Date and time when the account was created in ISO 8601 format (UTC).
profiles array Contains all the profiles under within the requested accounts.
profile_id number Unique identifier for the profile.
profile_name string The name of the profile.
date_created string Date and time when the profile was created in ISO 8601 format (UTC).

Example Response

    {
      "account_id": 5411295,
      "account_name": "WhatConverts",
      "date_created": "2016-06-24T17:24:42Z",
      "profiles": [ 
        {
          "profile_id": 2548713,
          "profile_name": "WhatConverts",
          "date_created": "2016-06-24T17:24:42Z"
        }
      ]
    }
    

Delete Account

Delete a single account.

Resource Details

Method Endpoint
DELETE https://app.whatconverts.com/api/v1/accounts/{account_id}

Supported Parameters

No supported parameters.

Response Details

Parameter Type Description
account_id number Unique identifier for the account.

Example Response

    {
      "account_id": 5411295
    }