Add Delegate User

Description

This API endpoint provides the ability to create a new delegate permission for a user based on their primary address. More information about delegates is available in Mimecaster Central

Pre-requisites

  • In order to successfully use this endpoint the logged in user must be a Mimecast administrator with at least the Directories | Internal | Create Alternate Address permission.

URI

To use this endpoint you send a POST request to:

  • /api/user/add-delegate-user

Request Headers

The following request headers must be included in your request:

Field Description
Authorization Please see the Authorization guide for more information on building the Authorization header.
x-mc-req-id

A randomly generated GUID, for example,

8578FCFC-A305-4D9A-99CB-F4D5ECEFE297
x-mc-app-id The Application ID provided with your Registered API Application.
x-mc-date

The current date and time in the following format, for example,

Tue, 24 Nov 2015 12:50:11 UTC

Request Body

{
"data": [
{
"delegateAddress": "String",
"primaryAddress": "String"
}
]
}
data
Field Type Required Description
primaryAddress String Required The primary email address of the user that will be granted delegate rights to another user
delegateAddress String Required The primary email address of the user that will be accessible by the primaryAddress user

Response

{
"fail": [],
"meta": {
"status": 200
},
"data": [
{
"id": "String",
"success": true/false  }
]
}
meta object
Field Type Description
status Number The function level status of the request.
meta
Field Type Description
status Number The function level status of the request.
data
Field Type Description
id String The Mimecast secure id of the created delegate right
success Boolean Returns true if the delgate right was applied, or will return false if unsuccessful

Sample Code

Sample code is provided to demonstrate how to use the API and is not representative of a production application. To use the sample code; complete the required variables as described, populate the desired values in the request body, and execute in your favorite IDE.  Please see the Global Base URL's page to find the correct base URL to use for your account.

POST {base_url}/api/user/add-delegate-user
Authorization: MC {accesskKey}:{Base64 encoded signed Data To Sign}
x-mc-date: {dateTime}
x-mc-req-id: {unique id}
x-mc-app-id: {applicationId}
Content-Type: application/json
Accept: application/json
{
"data":[
{
"primaryAddress": "String",
"delegateAddress": "String"
}
]
}
Back to Top