Creates a new OAuth 2.0 client registration.
Usage Example - M2M Client
POST /api/v1/auth/clients
Authorization: Bearer {token}
Content-Type: application/json
{
"displayName": "Salesforce Production Integration",
"m2m": true,
"botUserId": "bot-abc123"
}
Response:
{
"clientId": "oauth_client_xyz789",
"clientSecret": "secret_abcdef123456"
}
⚠️ CRITICAL: The clientSecret is only returned once. Store it securely immediately.
Usage Example - Interactive Client
POST /api/v1/auth/clients
Content-Type: application/json
{
"displayName": "My Web App",
"redirectUri": "https://myapp.example.com/oauth/callback",
"m2m": false
}
Next Steps (M2M)
Use client credentials to get access token:
POST /openid/token
Content-Type: application/x-www-form-urlencoded
grant_type=client_credentials
&client_id=oauth_client_xyz789
&client_secret=secret_abcdef123456
&scope=api:public
Body·CreateOAuthClientRequest
required
Client registration details
Request to create a new OAuth 2.0 client for API access.
- Type: booleanm2mrequired
Whether this is a machine-to-machine (M2M) client using client credentials flow.
- Type: null | stringbot
User Id max length:450Required bot user ID for M2M clients. Optional for interactive clients.
- Type: null | stringdisplay
Name max length:255Optional friendly name for this OAuth client (e.g., "Production CRM Integration").
- Type: null | stringredirect
Uri max length:2000Redirect URI for OAuth authorization code flow. Required for interactive flows, not needed for M2M flows.
Responses
- application/json
- application/problem+json
- application/problem+json
- application/problem+json
- application/problem+json
Request Example for post/api/v1/auth/clients
curl https://app.propstreet.com/api/v1/auth/clients \
--request POST \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer YOUR_SECRET_TOKEN' \
--data '{
"displayName": "Salesforce Production Integration",
"redirectUri": "https://myapp.example.com/oauth/callback",
"m2m": true,
"botUserId": "bot-abc123"
}'
{
"clientId": "oauth_client_abc123xyz",
"clientSecret": "secret_9876543210zyxwvutsrqponmlkjihgfedcba"
}