Workspaces
Upsert a Workspace
Changed onCreate or Update Workspace using ID or name.
put/workspaces/{WorkspaceIdOrName}
Request
- Base URLhttp://localhost:8001
- AuthAPI key in header Kong-Admin-Token
Path parameters
WorkspaceIdOrName, string required
ID or name of the Workspace to lookup
Request body
Workspace required
comment, string nullable
A description or additional information about the workspace.
config, object nullable
created_at, integer nullable
Unix epoch when the resource was created.
id, string nullable
A string representing a UUID (universally unique identifier).
meta, object nullable
name, string required
A unique string representing a UTF-8 encoded name.
updated_at, integer nullable
Unix epoch when the resource was last updated.
Example request
{
"comment": "Example workspace comment",
"config": {
"meta": {},
"portal": false,
"portal_access_request_email": true,
"portal_application_request_email": true,
"portal_application_status_email": true,
"portal_approved_email": true,
"portal_auth": "basic",
"portal_auth_conf": "some-auth-config",
"portal_auto_approve": true,
"portal_cors_origins": [
"https://example.com",
"https://another-origin.com"
],
"portal_developer_meta_fields": "[{\"label\":\"Full Name\",\"title\":\"full_name\",\"validator\":{\"required\":true,\"type\":\"string\"}}]",
"portal_emails_from": "admin@example.com",
"portal_emails_reply_to": "support@example.com",
"portal_invite_email": true,
"portal_is_legacy": false,
"portal_reset_email": true,
"portal_reset_success_email": true,
"portal_session_conf": "some-session-config",
"portal_smtp_admin_emails": [
"admin@example.com",
"dev@example.com"
],
"portal_token_exp": 3600
},
"created_at": 1706598432,
"id": "b58c7d9d-e54f-444c-b24d-cdfc4159f61e",
"meta": {
"color": "#ffcc00",
"thumbnail": "https://example.com/image.png"
},
"name": "example-workspace"
}Response
Successfully upserted Workspace
Workspace required
comment, string nullable
A description or additional information about the workspace.
config, object nullable
created_at, integer nullable
Unix epoch when the resource was created.
id, string nullable
A string representing a UUID (universally unique identifier).
meta, object nullable
name, string required
A unique string representing a UTF-8 encoded name.
updated_at, integer nullable
Unix epoch when the resource was last updated.
Example response
{
"comment": "Example workspace comment",
"config": {
"meta": {},
"portal": false,
"portal_access_request_email": true,
"portal_application_request_email": true,
"portal_application_status_email": true,
"portal_approved_email": true,
"portal_auth": "basic",
"portal_auth_conf": "some-auth-config",
"portal_auto_approve": true,
"portal_cors_origins": [
"https://example.com",
"https://another-origin.com"
],
"portal_developer_meta_fields": "[{\"label\":\"Full Name\",\"title\":\"full_name\",\"validator\":{\"required\":true,\"type\":\"string\"}}]",
"portal_emails_from": "admin@example.com",
"portal_emails_reply_to": "support@example.com",
"portal_invite_email": true,
"portal_is_legacy": false,
"portal_reset_email": true,
"portal_reset_success_email": true,
"portal_session_conf": "some-session-config",
"portal_smtp_admin_emails": [
"admin@example.com",
"dev@example.com"
],
"portal_token_exp": 3600
},
"created_at": 1706598432,
"id": "b58c7d9d-e54f-444c-b24d-cdfc4159f61e",
"meta": {
"color": "#ffcc00",
"thumbnail": "https://example.com/image.png"
},
"name": "example-workspace"
}Changes
- info
endpoint added
- info