Backend API
Create a new organization
cURL
curl --request POST \ --url https://api.wacht.dev/organizations \ --header 'Content-Type: multipart/form-data' \ --cookie session_id= \ --form 'name=Acme Corp' \ --form 'description=A leading technology company' \ --form image='@example-file'
{ "status": 200, "message": "", "data": { "organization": { "id": "123456789012345678", "deployment_id": "999999999999999999", "name": "Acme Corp", "description": "A leading technology company", "image_url": "https://cdn.wacht.dev/orgs/123/logo.png", "member_count": 42, "whitelisted_ips": [ "192.168.1.0/24" ], "enable_ip_restriction": false, "enforce_mfa": false, "auto_assigned_workspace_id": "555555555555555555", "public_metadata": { "industry": "Technology" }, "private_metadata": {}, "created_at": "2024-01-15T10:30:00Z", "updated_at": "2024-01-15T10:30:00Z" }, "membership": { "id": "333333333333333333", "organization_id": "123456789012345678", "user_id": "777777777777777777", "created_at": "2024-01-15T10:30:00Z", "updated_at": "2024-01-15T10:30:00Z" } }, "session": { "id": "123456789012345678", "created_at": "2023-11-07T05:31:56Z", "updated_at": "2023-11-07T05:31:56Z" }, "errors": [ { "code": "INVALID_CREDENTIALS", "message": "Invalid credentials. Please try again." } ] }
Session-based authentication using cookies
Organization name
"Acme Corp"
Organization description
"A leading technology company"
Organization profile image
Organization created successfully
HTTP status code
200
Response message (empty on success)
""
Show child attributes
Minimal session info included in every response
Error details (null on success)
Was this page helpful?