Management

Account Groups

List account groups for the authenticated user

GET
/v1/account-groups
AuthorizationBearer <token>

API key authentication - use your Late API key as a Bearer token

In: header

Response Body

application/json

application/json

curl -X GET "https://getlate.dev/api/v1/account-groups"
{
  "groups": [
    {
      "_id": "6507a1b2c3d4e5f6a7b8c9d0",
      "name": "Marketing Accounts",
      "accountIds": [
        "64e1f0a9e2b5af0012ab34cd",
        "64e1f0a9e2b5af0012ab34ce"
      ]
    },
    {
      "_id": "6507a1b2c3d4e5f6a7b8c9d1",
      "name": "Personal Brand",
      "accountIds": [
        "64e1f0a9e2b5af0012ab34cf"
      ]
    }
  ]
}
{
  "error": "Unauthorized"
}

Create a new account group

POST
/v1/account-groups
AuthorizationBearer <token>

API key authentication - use your Late API key as a Bearer token

In: header

namestring
accountIdsarray<string>

Response Body

application/json

application/json

curl -X POST "https://getlate.dev/api/v1/account-groups" \  -H "Content-Type: application/json" \  -d '{    "name": "Marketing Accounts",    "accountIds": [      "64e1f0a9e2b5af0012ab34cd",      "64e1f0a9e2b5af0012ab34ce"    ]  }'
{
  "message": "Account group created successfully",
  "group": {
    "_id": "6507a1b2c3d4e5f6a7b8c9d0",
    "name": "Marketing Accounts",
    "accountIds": [
      "64e1f0a9e2b5af0012ab34cd",
      "64e1f0a9e2b5af0012ab34ce"
    ]
  }
}
Empty
{
  "error": "Unauthorized"
}
Empty

Delete an account group

DELETE
/v1/account-groups/{groupId}
AuthorizationBearer <token>

API key authentication - use your Late API key as a Bearer token

In: header

Path Parameters

groupIdstring

Response Body

application/json

application/json

application/json

curl -X DELETE "https://getlate.dev/api/v1/account-groups/string"
{
  "message": "Account group deleted successfully"
}
{
  "error": "Unauthorized"
}
{
  "error": "Not found"
}

Update an account group

PUT
/v1/account-groups/{groupId}
AuthorizationBearer <token>

API key authentication - use your Late API key as a Bearer token

In: header

Path Parameters

groupIdstring
name?string
accountIds?array<string>

Response Body

application/json

application/json

application/json

curl -X PUT "https://getlate.dev/api/v1/account-groups/string" \  -H "Content-Type: application/json" \  -d '{    "name": "Updated Marketing Accounts",    "accountIds": [      "64e1f0a9e2b5af0012ab34cd",      "64e1f0a9e2b5af0012ab34ce",      "64e1f0a9e2b5af0012ab34cf"    ]  }'
{
  "message": "Account group updated successfully",
  "group": {
    "_id": "6507a1b2c3d4e5f6a7b8c9d0",
    "name": "Updated Marketing Accounts",
    "accountIds": [
      "64e1f0a9e2b5af0012ab34cd",
      "64e1f0a9e2b5af0012ab34ce",
      "64e1f0a9e2b5af0012ab34cf"
    ]
  }
}
{
  "error": "Unauthorized"
}
{
  "error": "Not found"
}
Empty