Substy Developers
Team

Create team schedule

Create AI or employee work schedules for the selected creators, dates and time slots. Specify the intended timezone and recurrence settings.

POST/v1/agencies/{agencyId}/team/schedules

Create AI or employee work schedules for the selected creators, dates and time slots. Specify the intended timezone and recurrence settings.

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Path Parameters

agencyId*string
Length1 <= length

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://example.com/v1/agencies/string/team/schedules" \  -H "Authorization: Bearer YOUR_API_KEY" \  -H "Content-Type: application/json" \  -d '{    "creatorIds": [      "string"    ],    "dates": [      "2019-08-24T14:15:22Z"    ],    "timeSlots": [      {        "startTime": "string",        "endTime": "string"      }    ]  }'
{  "data": {    "timeSlots": [      {        "id": "string",        "createdAt": "2019-08-24T14:15:22Z",        "updatedAt": "2019-08-24T14:15:22Z",        "startTime": "string",        "endTime": "string",        "position": 0,        "dayOfWeek": null,        "scheduleId": "string"      }    ],    "creators": [      {        "creator": {          "platform": "ONLYFANS",          "id": "string",          "name": "string"        },        "creatorId": "string",        "scheduleId": "string",        "assignedAt": "2019-08-24T14:15:22Z"      }    ],    "employees": [      {        "agencyEmployee": {          "id": "string",          "color": null,          "employeeId": "string"        },        "scheduleId": "string",        "assignedAt": "2019-08-24T14:15:22Z",        "agencyEmployeeId": "string"      }    ],    "scheduleDates": [      {        "date": "2019-08-24T14:15:22Z",        "id": "string",        "createdAt": "2019-08-24T14:15:22Z",        "scheduleId": "string"      }    ],    "id": "string",    "createdAt": "2019-08-24T14:15:22Z",    "status": "COMPLETED",    "timezone": "string",    "updatedAt": "2019-08-24T14:15:22Z",    "scheduledFor": "AI",    "isAllDay": true,    "isRecurring": true,    "recurrenceType": null,    "recurrenceEnd": null,    "color": null,    "isCompleted": true,    "completedAt": null,    "lastOccurrenceStart": null  },  "meta": {    "requestId": "string",    "operationId": "3051932a-fdd2-48fa-b330-7e7d41535969",    "status": "COMPLETED"  }}