Choose the synced email folders

Replaces the set of email folders that sync, as the account's Folders tab does. Pass folder ids from GET /v1/messaging/connected-accounts; unknown ids are ignored, and newly enabled folders sync in the background. Only the account owner can change it; another member's account answers 404. Returns the saved account. Requires: Inbox messages Edit.

POST
/v1/messaging/connected-accounts/{id}/folders

Authorization

apiKeyAuth
x-api-key<token>

API key authentication. Create an API key in your user profile and include it in the x-api-key header.

In: header

Path Parameters

id*string
Match^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
Formatuuid

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://customermates.com/api/v1/messaging/connected-accounts/497f6eca-6276-4993-bfeb-53cbbbba6f08/folders" \  -H "Content-Type: application/json" \  -d '{    "selectedFolderIds": [      "string"    ]  }'
{
  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  "provider": "google",
  "status": "ok",
  "hasMessaging": true,
  "hasCalendar": true,
  "emailAddress": "string",
  "displayName": "string",
  "shared": true,
  "syncing": true,
  "lastSyncedAt": "string",
  "createdAt": "string",
  "owner": {
    "userId": "2c4a230c-5085-4924-a3e1-25fb4fc5965b",
    "firstName": "string",
    "lastName": "string",
    "avatarUrl": "string"
  },
  "isOwner": true,
  "folders": [],
  "selectedFolderIds": [],
  "foldersSyncedAt": "string",
  "linkedinProducts": [],
  "signature": null,
  "emailSettings": {
    "version": 2,
    "appearance": {
      "fontFamily": "sansSerif",
      "fontSize": 13,
      "linkHex": "#7161e8",
      "linkStyle": "underlined"
    },
    "signature": {
      "enabled": false,
      "template": "stacked",
      "logoUrl": "https://customermates.com/images/email/customermates-icon@2x.png",
      "logoSize": "medium",
      "divider": "none",
      "spacing": "comfortable"
    }
  },
  "signatureHtml": null
}
{
  "error": {
    "kind": "validation",
    "issues": [
      {
        "code": "string",
        "path": [
          "string"
        ],
        "message": "string",
        "customCode": "recordNotFound",
        "entitlement": "string"
      }
    ],
    "retryable": true
  }
}
{
  "error": {
    "kind": "validation",
    "issues": [
      {
        "code": "string",
        "path": [
          "string"
        ],
        "message": "string",
        "customCode": "recordNotFound",
        "entitlement": "string"
      }
    ],
    "retryable": true
  }
}
{
  "error": {
    "kind": "validation",
    "issues": [
      {
        "code": "string",
        "path": [
          "string"
        ],
        "message": "string",
        "customCode": "recordNotFound",
        "entitlement": "string"
      }
    ],
    "retryable": true
  }
}
{
  "error": {
    "kind": "validation",
    "issues": [
      {
        "code": "string",
        "path": [
          "string"
        ],
        "message": "string",
        "customCode": "recordNotFound",
        "entitlement": "string"
      }
    ],
    "retryable": true
  }
}
{
  "error": {
    "kind": "validation",
    "issues": [
      {
        "code": "string",
        "path": [
          "string"
        ],
        "message": "string",
        "customCode": "recordNotFound",
        "entitlement": "string"
      }
    ],
    "retryable": true
  }
}
{
  "error": {
    "kind": "validation",
    "issues": [
      {
        "code": "string",
        "path": [
          "string"
        ],
        "message": "string",
        "customCode": "recordNotFound",
        "entitlement": "string"
      }
    ],
    "retryable": true
  }
}
{
  "error": {
    "kind": "validation",
    "issues": [
      {
        "code": "string",
        "path": [
          "string"
        ],
        "message": "string",
        "customCode": "recordNotFound",
        "entitlement": "string"
      }
    ],
    "retryable": true
  }
}
Empty