Skip to content

Create a SAML provider.

POST
/api/admin/saml-providers
Code sample: Shell / cURL
curl --request POST \
--url https://auth.example.com/api/admin/saml-providers \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "name": "Example SAML IdP", "providerType": "saml_idp", "config": { "entityId": "https://idp.example.com/metadata", "ssoUrl": "https://idp.example.com/sso", "certificate": "-----BEGIN CERTIFICATE-----..." } }'
Media type application/json
object
name
required
string
providerType
required
string
Allowed values: saml_idp saml_sp
config
object
entityId
string
ssoUrl
string format: uri
acsUrl
string format: uri
certificate
string
metadataUrl
string format: uri
metadataXml
string
<= 1048576 characters
metadataRefreshPolicy
object
mode
required

URL-backed providers default to automatic when this property is omitted.

string
Allowed values: automatic manual
intervalSeconds
required
integer
default: 21600 >= 900 <= 604800
nextRefreshAt
integer format: int64
lastAttemptAt
integer format: int64
lastSuccessAt
integer format: int64
consecutiveFailures
integer
sourceState
string
Allowed values: healthy stale error expired missing identity_change_pending
lastErrorCode
string
suspendedByMetadataSync

True when metadata lifecycle automation disabled the provider.

boolean
key
additional properties
nameIdFormat
string
metadataNameIdFormats
Array<string>
identityMapping
object
fieldMappingSetId
required
string
fieldMappingVersionId
string
destinationNamespace
string
destinationFieldPolicies

Per-SP release mode for every attribute in the active SAML Destination Profile.

object
key
additional properties
string
Allowed values: required optional hidden
key
additional properties
attributeReleaseConsent
object
enabled
boolean
mode
string
Allowed values: once every_time until_attributes_change
key
additional properties
key
additional properties
enabled

Defaults to true. A Field Mapping Set is required when true. When false, the provider may be registered without identityMapping and configured later from its detail page.

boolean
metadataUrl
string format: uri
metadataXml
string
<= 1048576 characters
samlProfile
string
attributePresetId
string
Example
{
"name": "Example SAML IdP",
"providerType": "saml_idp",
"config": {
"entityId": "https://idp.example.com/metadata",
"ssoUrl": "https://idp.example.com/sso",
"certificate": "-----BEGIN CERTIFICATE-----..."
}
}

Successful JSON response.

Media type application/json
object
id
required
string
name
required
string
providerType
required
string
Allowed values: saml_idp saml_sp
config
required
object
entityId
string
ssoUrl
string format: uri
acsUrl
string format: uri
certificate
string
metadataUrl
string format: uri
metadataXml
string
<= 1048576 characters
metadataRefreshPolicy
object
mode
required

URL-backed providers default to automatic when this property is omitted.

string
Allowed values: automatic manual
intervalSeconds
required
integer
default: 21600 >= 900 <= 604800
nextRefreshAt
integer format: int64
lastAttemptAt
integer format: int64
lastSuccessAt
integer format: int64
consecutiveFailures
integer
sourceState
string
Allowed values: healthy stale error expired missing identity_change_pending
lastErrorCode
string
suspendedByMetadataSync

True when metadata lifecycle automation disabled the provider.

boolean
key
additional properties
nameIdFormat
string
metadataNameIdFormats
Array<string>
identityMapping
object
fieldMappingSetId
required
string
fieldMappingVersionId
string
destinationNamespace
string
destinationFieldPolicies

Per-SP release mode for every attribute in the active SAML Destination Profile.

object
key
additional properties
string
Allowed values: required optional hidden
key
additional properties
attributeReleaseConsent
object
enabled
boolean
mode
string
Allowed values: once every_time until_attributes_change
key
additional properties
key
additional properties
enabled
required
boolean
createdAt
string format: date-time
updatedAt
string format: date-time
Example
{
"id": "provider_123",
"name": "Example SAML IdP",
"providerType": "saml_idp",
"config": {
"entityId": "https://idp.example.com/metadata",
"ssoUrl": "https://idp.example.com/sso"
},
"enabled": true,
"createdAt": "2026-06-19T00:00:00.000Z",
"updatedAt": "2026-06-19T00:00:00.000Z"
}

Successful JSON response.

Media type application/json
object
id
required
string
name
required
string
providerType
required
string
Allowed values: saml_idp saml_sp
config
required
object
entityId
string
ssoUrl
string format: uri
acsUrl
string format: uri
certificate
string
metadataUrl
string format: uri
metadataXml
string
<= 1048576 characters
metadataRefreshPolicy
object
mode
required

URL-backed providers default to automatic when this property is omitted.

string
Allowed values: automatic manual
intervalSeconds
required
integer
default: 21600 >= 900 <= 604800
nextRefreshAt
integer format: int64
lastAttemptAt
integer format: int64
lastSuccessAt
integer format: int64
consecutiveFailures
integer
sourceState
string
Allowed values: healthy stale error expired missing identity_change_pending
lastErrorCode
string
suspendedByMetadataSync

True when metadata lifecycle automation disabled the provider.

boolean
key
additional properties
nameIdFormat
string
metadataNameIdFormats
Array<string>
identityMapping
object
fieldMappingSetId
required
string
fieldMappingVersionId
string
destinationNamespace
string
destinationFieldPolicies

Per-SP release mode for every attribute in the active SAML Destination Profile.

object
key
additional properties
string
Allowed values: required optional hidden
key
additional properties
attributeReleaseConsent
object
enabled
boolean
mode
string
Allowed values: once every_time until_attributes_change
key
additional properties
key
additional properties
enabled
required
boolean
createdAt
string format: date-time
updatedAt
string format: date-time
Example
{
"id": "provider_123",
"name": "Example SAML IdP",
"providerType": "saml_idp",
"config": {
"entityId": "https://idp.example.com/metadata",
"ssoUrl": "https://idp.example.com/sso"
},
"enabled": true,
"createdAt": "2026-06-19T00:00:00.000Z",
"updatedAt": "2026-06-19T00:00:00.000Z"
}