Skip to content

API Key

MailCarry offers a list of its functions to access, save, update and retrieve programmatically using the APIs. From managing lists, recipients and email campaigns, you can perform several functions. To learn more about the API structure with examples, you can refer to the API Documentation section. In this document, we’ll learn about generating the important resources required for all the functions to execute properly through API requests.

In this Article..

  • Where can I get my API Key?
  • How can I regenerate the API Key?

Status

An option to deactivate the API function, by default the API function is set as Active. If you work this toggle option to mark the API function as “Inactive”, the system will not entertain any API requests for the current installation.

Generate API Key

MailCarry requires authentication to determine that the API request is initiated through a valid installation having a valid product license. A valid API key is used as an authentication token. When you click on “API” from the main navigation, the resulting page will show an API Key in its respective field. This is a valid key that you can copy by clicking the “Copy” icon towards the edge of the field and can use this key to form a valid API structure for requesting a function.

Regenerate API Key

Every MailCarry installation has a valid API key readily available for you to copy and use to work with the available API functions. You don’t have to generate this first key in your account. However, if you think your existing key is compromised, or you don’t want to use this default set key for your MailCarry installation, you can click the button “regenerate” next to the API Key field, and you’ll see that the system will regenerate a new key for your account.

If you regenerate the API key, your existing API key will turn invalid. If you’re sending an API request with an old key, you’ll get the authentication error. If you’re already interacting MailCarry from a 3rd party application, make sure you update all custom codes with a new API key after regenerating.

Note (Regenerating the API Key)

API Base URL

Apart from the API key, every API request requires a qualified API path that mostly comprises of Base URL/ Function Name and sometimes /{id} of the resource to update/retrieve. It is like when you request some page through a browser, you’ll type a complete path in your browser address bar for the page to appear on your screen. This specific field provides the base URL to help you easily use this while sending an API request. For example, to delete a list programmatically through the API, you would need to have the following path in your API request to execute.

Structure-Base-URL/Function Name/{id}

Copy the URL from base URL field/function name, in this case, is custom-fields/{id} the id of the list.

Was this article helpful?
How can we improve this article?

Copyright © 2020 MailCarry