curl --request PATCH \
--url https://sapi.withsutro.com/applications/{applicationId}/cors \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'x-sutro-api-client: <api-key>' \
--data '
{
"allowedOrigins": [
"http://localhost:8080",
"https://app.example.com"
]
}
'{
"allowedOrigins": [
"http://localhost:8080",
"https://app.example.com"
]
}Updates the CORS configuration for the application’s backend API. This is required when self-hosting the frontend to allow cross-origin requests.
curl --request PATCH \
--url https://sapi.withsutro.com/applications/{applicationId}/cors \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'x-sutro-api-client: <api-key>' \
--data '
{
"allowedOrigins": [
"http://localhost:8080",
"https://app.example.com"
]
}
'{
"allowedOrigins": [
"http://localhost:8080",
"https://app.example.com"
]
}Builder authentication and authorization
A unique identifier for the API Client making a request
CORS (Cross-Origin Resource Sharing) configuration for the application's backend API
List of allowed origins that can make cross-origin requests to the backend API
[
"http://localhost:8080",
"https://app.example.com"
]The updated CORS configuration
CORS (Cross-Origin Resource Sharing) configuration for the application's backend API
List of allowed origins that can make cross-origin requests to the backend API
[
"http://localhost:8080",
"https://app.example.com"
]Was this page helpful?