SureshakeDocs
API ReferenceEndpoints

Entity Endpoints

Manage entities, team members, and settings.

Entity endpoints manage organization-level profile and access control data.

List Entities

Retrieve a paginated list of entities.

GET/api/v1/entities
curl -H "Authorization: Bearer $TOKEN" https://api.sureshake.com/api/v1/entities
const response = await fetch('https://api.sureshake.com/api/v1/entities', {
headers: { 'Authorization': `Bearer ${token}` }
});
const { data, meta } = await response.json();
200 OK
{
"data": [
  {
    "id": "8f2349ef-22ab-46ae-a129-2eb4c2570001",
    "name": "Acme Corp",
    "slug": "acme-corp",
    "entityType": "company",
    "ownerId": "user_123",
    "createdAt": "2024-01-10T10:00:00Z",
    "updatedAt": "2024-01-10T10:00:00Z"
  }
],
"meta": {
  "total": 1,
  "limit": 20,
  "offset": 0,
  "hasMore": false
}
}

Create Entity

Create a new entity (company, fund, etc.)

POST/api/v1/entities
curl -X POST \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"name": "New Entity", "entityType": "company"}' \
https://api.sureshake.com/api/v1/entities
const response = await fetch('https://api.sureshake.com/api/v1/entities', {
method: 'POST',
headers: {
  'Authorization': `Bearer ${token}`,
  'Content-Type': 'application/json'
},
body: JSON.stringify({
  name: 'New Entity',
  entityType: 'company'
})
});

Get Entity

Retrieve a single entity by its ID.

GET/api/v1/entities/:id
curl -H "Authorization: Bearer $TOKEN" https://api.sureshake.com/api/v1/entities/8f2349ef...

Update Entity

Update entity metadata.

PATCH/api/v1/entities/:id
curl -X PATCH \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"name": "Updated Acme"}' \
https://api.sureshake.com/api/v1/entities/8f2349ef...

On this page