Workspace settings
Get workspace
get/v1/workspace
Get the current workspace's settings as the settings page shows them: name, logo, approval mode, review locking, campaigns, timezone and posting times, the approval modes the plan allows, and the caller's permissions. Needs workspace:view.
Response 200
Workspace
idstringrequirednamestringrequiredlogoUrlstringrequirednullableapprovalModestringrequiredOne of
noneoptionalrequiredmulti_levellockDuringReviewbooleanrequiredcampaignsEnabledbooleanrequiredsettingsobjectrequiredChild attributes
autoScheduleOnApprovalbooleanrequiredtimezonestringrequirednullablepostingPreferencesobjectrequiredChild attributes
defaultPostingTimesobjectrequiredChild attributes
morningstringrequiredPattern ^(?:[01]\d|2[0-3]):[0-5]\d$
middaystringrequiredPattern ^(?:[01]\d|2[0-3]):[0-5]\d$
laterAfternoonstringrequiredPattern ^(?:[01]\d|2[0-3]):[0-5]\d$
otherstringrequiredPattern ^(?:[01]\d|2[0-3]):[0-5]\d$
showDefaultPostingTimesbooleanrequiredtimeWiggleEnabledbooleanrequired
allowedApprovalModesarray of stringrequiredOne of
noneoptionalrequiredmulti_levelpermissionsarray of stringrequired
Errors
- 401
- Unauthenticated
- 403
- Missing workspace:view
curl "https://api.posty.social/v1/workspace" \
-H "Authorization: Bearer $POSTY_API_KEY"{
"id": "string",
"name": "string",
"logoUrl": "string",
"approvalMode": "none",
"lockDuringReview": true,
"campaignsEnabled": true,
"settings": {
"autoScheduleOnApproval": true,
"timezone": "string",
"postingPreferences": {
"defaultPostingTimes": {
"morning": "string",
"midday": "string",
"laterAfternoon": "string",
"other": "string"
},
"showDefaultPostingTimes": true,
"timeWiggleEnabled": true
}
},
"allowedApprovalModes": [
"none"
],
"permissions": [
"string"
]
}Update workspace settings
patch/v1/workspace
Update the current workspace's name, approval mode, review locking, campaigns switch, timezone, auto scheduling on approval or default posting times. Only the fields you send change. An approval mode outside the plan's allowedApprovalModes is refused. Needs workspace:update.
Request body
namestringMin length 1 · Max length 30
approvalModestringOne of
noneoptionalrequiredmulti_levellockDuringReviewbooleancampaignsEnabledbooleansettingsobjectChild attributes
autoScheduleOnApprovalbooleantimezonestringMin length 1 · Max length 100
postingPreferencesobjectChild attributes
defaultPostingTimesobjectChild attributes
morningstringPattern ^(?:[01]\d|2[0-3]):[0-5]\d$
middaystringPattern ^(?:[01]\d|2[0-3]):[0-5]\d$
laterAfternoonstringPattern ^(?:[01]\d|2[0-3]):[0-5]\d$
otherstringPattern ^(?:[01]\d|2[0-3]):[0-5]\d$
showDefaultPostingTimesbooleantimeWiggleEnabledboolean
Response 200
Workspace updated
idstringrequirednamestringrequiredlogoUrlstringrequirednullableapprovalModestringrequiredOne of
noneoptionalrequiredmulti_levellockDuringReviewbooleanrequiredcampaignsEnabledbooleanrequiredsettingsobjectrequiredChild attributes
autoScheduleOnApprovalbooleanrequiredtimezonestringrequirednullablepostingPreferencesobjectrequiredChild attributes
defaultPostingTimesobjectrequiredChild attributes
morningstringrequiredPattern ^(?:[01]\d|2[0-3]):[0-5]\d$
middaystringrequiredPattern ^(?:[01]\d|2[0-3]):[0-5]\d$
laterAfternoonstringrequiredPattern ^(?:[01]\d|2[0-3]):[0-5]\d$
otherstringrequiredPattern ^(?:[01]\d|2[0-3]):[0-5]\d$
showDefaultPostingTimesbooleanrequiredtimeWiggleEnabledbooleanrequired
Errors
- 400
- Invalid request
- 401
- Unauthenticated
- 403
- Missing workspace:update, or approval mode not on the plan
curl -X PATCH "https://api.posty.social/v1/workspace" \
-H "Authorization: Bearer $POSTY_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "string",
"approvalMode": "none",
"lockDuringReview": true,
"campaignsEnabled": true,
"settings": {
"autoScheduleOnApproval": true,
"timezone": "string",
"postingPreferences": {
"defaultPostingTimes": {
"morning": "string",
"midday": "string",
"laterAfternoon": "string",
"other": "string"
},
"showDefaultPostingTimes": true,
"timeWiggleEnabled": true
}
}
}'{
"id": "string",
"name": "string",
"logoUrl": "string",
"approvalMode": "none",
"lockDuringReview": true,
"campaignsEnabled": true,
"settings": {
"autoScheduleOnApproval": true,
"timezone": "string",
"postingPreferences": {
"defaultPostingTimes": {
"morning": "string",
"midday": "string",
"laterAfternoon": "string",
"other": "string"
},
"showDefaultPostingTimes": true,
"timeWiggleEnabled": true
}
}
}