(samlConnections)
- list - Get a list of SAML Connections for an instance
- create - Create a SAML Connection
- get - Retrieve a SAML Connection by ID
- update - Update a SAML Connection
- delete - Delete a SAML Connection
Returns the list of SAML Connections for an instance.
Results can be paginated using the optional limit
and offset
query parameters.
The SAML Connections are ordered by descending creation date and the most recent will be returned first.
declare(strict_types=1);
require 'vendor/autoload.php';
use Clerk\Backend;
$security = '<YOUR_BEARER_TOKEN_HERE>';
$sdk = Backend\ClerkBackend::builder()->setSecurity($security)->build();
$response = $sdk->samlConnections->list(
limit: 10,
offset: 0
);
if ($response->samlConnections !== null) {
// handle response
}
Parameter | Type | Required | Description |
---|---|---|---|
limit |
?int | ➖ | Applies a limit to the number of results returned. Can be used for paginating the results together with offset . |
offset |
?int | ➖ | Skip the first offset results when paginating.Needs to be an integer greater or equal to zero. To be used in conjunction with limit . |
?Operations\ListSAMLConnectionsResponse
Error Type | Status Code | Content Type |
---|---|---|
Errors\ClerkErrors99 | 402, 403, 422 | application/json |
Errors\SDKException | 4XX, 5XX | */* |
Create a new SAML Connection.
declare(strict_types=1);
require 'vendor/autoload.php';
use Clerk\Backend;
use Clerk\Backend\Models\Operations;
$security = '<YOUR_BEARER_TOKEN_HERE>';
$sdk = Backend\ClerkBackend::builder()->setSecurity($security)->build();
$request = new Operations\CreateSAMLConnectionRequestBody(
name: '<value>',
domain: 'low-packaging.info',
provider: Operations\Provider::SamlCustom,
);
$response = $sdk->samlConnections->create(
request: $request
);
if ($response->schemasSAMLConnection !== null) {
// handle response
}
Parameter | Type | Required | Description |
---|---|---|---|
$request |
Operations\CreateSAMLConnectionRequestBody | ✔️ | The request object to use for the request. |
?Operations\CreateSAMLConnectionResponse
Error Type | Status Code | Content Type |
---|---|---|
Errors\ClerkErrors100 | 402, 403, 422 | application/json |
Errors\SDKException | 4XX, 5XX | */* |
Fetches the SAML Connection whose ID matches the provided saml_connection_id
in the path.
declare(strict_types=1);
require 'vendor/autoload.php';
use Clerk\Backend;
$security = '<YOUR_BEARER_TOKEN_HERE>';
$sdk = Backend\ClerkBackend::builder()->setSecurity($security)->build();
$response = $sdk->samlConnections->get(
samlConnectionId: '<id>'
);
if ($response->schemasSAMLConnection !== null) {
// handle response
}
Parameter | Type | Required | Description |
---|---|---|---|
samlConnectionId |
string | ✔️ | The ID of the SAML Connection |
?Operations\GetSAMLConnectionResponse
Error Type | Status Code | Content Type |
---|---|---|
Errors\ClerkErrors101 | 402, 403, 404 | application/json |
Errors\SDKException | 4XX, 5XX | */* |
Updates the SAML Connection whose ID matches the provided id
in the path.
declare(strict_types=1);
require 'vendor/autoload.php';
use Clerk\Backend;
use Clerk\Backend\Models\Operations;
$security = '<YOUR_BEARER_TOKEN_HERE>';
$sdk = Backend\ClerkBackend::builder()->setSecurity($security)->build();
$requestBody = new Operations\UpdateSAMLConnectionRequestBody();
$response = $sdk->samlConnections->update(
samlConnectionId: '<id>',
requestBody: $requestBody
);
if ($response->schemasSAMLConnection !== null) {
// handle response
}
Parameter | Type | Required | Description |
---|---|---|---|
samlConnectionId |
string | ✔️ | The ID of the SAML Connection to update |
requestBody |
Operations\UpdateSAMLConnectionRequestBody | ✔️ | N/A |
?Operations\UpdateSAMLConnectionResponse
Error Type | Status Code | Content Type |
---|---|---|
Errors\ClerkErrors102 | 402, 403, 404, 422 | application/json |
Errors\SDKException | 4XX, 5XX | */* |
Deletes the SAML Connection whose ID matches the provided id
in the path.
declare(strict_types=1);
require 'vendor/autoload.php';
use Clerk\Backend;
$security = '<YOUR_BEARER_TOKEN_HERE>';
$sdk = Backend\ClerkBackend::builder()->setSecurity($security)->build();
$response = $sdk->samlConnections->delete(
samlConnectionId: '<id>'
);
if ($response->deletedObject !== null) {
// handle response
}
Parameter | Type | Required | Description |
---|---|---|---|
samlConnectionId |
string | ✔️ | The ID of the SAML Connection to delete |
?Operations\DeleteSAMLConnectionResponse
Error Type | Status Code | Content Type |
---|---|---|
Errors\ClerkErrors103 | 402, 403, 404 | application/json |
Errors\SDKException | 4XX, 5XX | */* |