Create Identity
client.identities.create(IdentityCreateParams { identifier_key, identity_type, name, 4 more } body, RequestOptionsoptions?): Identity { id, agent_ids, block_ids, 5 more }
/v1/identities/
Create Identity
Parameters
Returns
Create Identity
import Letta from '@letta-ai/letta-client';
const client = new Letta({
apiKey: 'My API Key',
});
const identity = await client.identities.create({
identifier_key: 'identifier_key',
identity_type: 'org',
name: 'name',
});
console.log(identity.id);
{
"id": "identity-123e4567-e89b-12d3-a456-426614174000",
"agent_ids": [
"string"
],
"block_ids": [
"string"
],
"identifier_key": "identifier_key",
"identity_type": "org",
"name": "name",
"project_id": "project_id",
"properties": [
{
"key": "key",
"type": "string",
"value": "string"
}
]
}Returns Examples
{
"id": "identity-123e4567-e89b-12d3-a456-426614174000",
"agent_ids": [
"string"
],
"block_ids": [
"string"
],
"identifier_key": "identifier_key",
"identity_type": "org",
"name": "name",
"project_id": "project_id",
"properties": [
{
"key": "key",
"type": "string",
"value": "string"
}
]
}