Expensicat
API Reference

Members

GET
/v1/members

List all organization members with optional role filtering

Authorization

bearerAuth
AuthorizationBearer <token>

Session JWT or OAuth2 access token

In: header

Query Parameters

role?string

Response Body

application/json

application/json

curl -X GET "https://example.com/v1/members"
{
  "data": [
    {
      "id": "string",
      "role": "owner",
      "user": {
        "id": "string",
        "email": "string",
        "full_name": "string",
        "avatar_url": "string"
      }
    }
  ],
  "meta": {
    "count": 0,
    "next_cursor": "string"
  }
}
{
  "error": {
    "code": "string",
    "message": "string",
    "details": {
      "property1": null,
      "property2": null
    }
  }
}
PATCH
/v1/members/{userId}

Update a member's role (admin or member)

Authorization

bearerAuth
AuthorizationBearer <token>

Session JWT or OAuth2 access token

In: header

Path Parameters

userId*string

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

curl -X PATCH "https://example.com/v1/members/string" \  -H "Content-Type: application/json" \  -d '{    "role": "admin"  }'
{
  "data": {
    "id": "string",
    "role": "owner",
    "user": {
      "id": "string",
      "email": "string",
      "full_name": "string",
      "avatar_url": "string"
    }
  }
}
{
  "error": {
    "code": "string",
    "message": "string",
    "details": {
      "property1": null,
      "property2": null
    }
  }
}
{
  "error": {
    "code": "string",
    "message": "string",
    "details": {
      "property1": null,
      "property2": null
    }
  }
}
DELETE
/v1/members/{userId}

Remove a member from the organization

Authorization

bearerAuth
AuthorizationBearer <token>

Session JWT or OAuth2 access token

In: header

Path Parameters

userId*string

Response Body

application/json

application/json

curl -X DELETE "https://example.com/v1/members/string"
Empty
{
  "error": {
    "code": "string",
    "message": "string",
    "details": {
      "property1": null,
      "property2": null
    }
  }
}
{
  "error": {
    "code": "string",
    "message": "string",
    "details": {
      "property1": null,
      "property2": null
    }
  }
}