Skip to main content

What is a Recipient ID?

A recipient ID is a unique identifier assigned to each recipient associated with a client in your workspace. It’s required for making API requests that interact with specific recipients, such as updating recipient details or deleting recipients.

Step-by-Step Instructions

1

Make the API request

Send a GET request to the Get client details API endpoint, including your API key in the request header.
2

Parse the response

The response will contain a recipients array with recipient objects, each containing an id field.Example:
{
  "client": {
    "id": "a8b90a464cad12b48e45",
    "name": "Neeto Client Inc.",
    "status": "active",
    // ... rest of the details
  },
  "recipients": [
    {
      "id": "128c1dfc-b29f-4fda-9a05-8a90e197b81b",
      "name": "Tim Bradford",
      "email": "[email protected]",
      "client_id": "a8b90a464cad12b48e45",
      "created_at": "2024-01-15T10:30:00Z",
      "updated_at": "2024-01-15T10:30:00Z"
    },
    {
      "id": "6be815a8-9a10-455c-95d9-b0b548664420",
      "name": "Jane Smith",
      "email": "[email protected]",
      "client_id": "a8b90a464cad12b48e45",
      "created_at": "2024-01-16T09:15:00Z",
      "updated_at": "2024-01-16T09:15:00Z"
    }
  ]
}
3

Extract the recipient ID

Here the recipient ID for Tim Bradford is: 128c1dfc-b29f-4fda-9a05-8a90e197b81b.You can access the recipient ID in your code from the response using:
// Get the first recipient's ID
const recipientId = response.recipients[0].id;

// Or iterate through all recipients to find a specific one
const timRecipient = response.recipients.find(recipient => recipient.name === "Tim Bradford");
const timRecipientId = timRecipient.id;