Returns a list of all clients. The clients are returned sorted by creation date, with the newest clients appearing first. Warning: the endpoint is being deprecated and will be removed in future versions.
⚠️ DEPRECATED: This will be removed in a future release, please migrate away from it as soon as possible.
require 'clerk_sdk_ruby'
Models = ::Clerk::Models
s = ::Clerk::OpenAPIClient.new(
bearer_auth: '<YOUR_BEARER_TOKEN_HERE>'
)
res = s.clients.list(limit: 10, offset: 0)
unless res.client_list.nil?
# handle response
end| Parameter | Type | Required | Description |
|---|---|---|---|
paginated |
Crystalline::Nilable.new(Crystalline::Boolean.new) | ➖ | Whether to paginate the results. If true, the results will be paginated. If false, the results will not be paginated. |
limit |
Crystalline::Nilable.new(::Integer) | ➖ | Applies a limit to the number of results returned. Can be used for paginating the results together with offset. |
offset |
Crystalline::Nilable.new(::Integer) | ➖ | Skip the first offset results when paginating.Needs to be an integer greater or equal to zero. To be used in conjunction with limit. |
Crystalline::Nilable.new(Models::Operations::GetClientListResponse)
| Error Type | Status Code | Content Type |
|---|---|---|
| Models::Errors::ClerkErrors | 400, 401, 410, 422 | application/json |
| Errors::APIError | 4XX, 5XX | */* |
Verifies the client in the provided token
require 'clerk_sdk_ruby'
Models = ::Clerk::Models
s = ::Clerk::OpenAPIClient.new(
bearer_auth: '<YOUR_BEARER_TOKEN_HERE>'
)
req = Models::Operations::VerifyClientRequest.new(
token: 'jwt_token_example'
)
res = s.clients.verify(request: req)
unless res.client.nil?
# handle response
end| Parameter | Type | Required | Description |
|---|---|---|---|
request |
Models::Operations::VerifyClientRequest | ✔️ | The request object to use for the request. |
Crystalline::Nilable.new(Models::Operations::VerifyClientResponse)
| Error Type | Status Code | Content Type |
|---|---|---|
| Models::Errors::ClerkErrors | 400, 401, 404 | application/json |
| Errors::APIError | 4XX, 5XX | */* |
Returns the details of a client.
require 'clerk_sdk_ruby'
Models = ::Clerk::Models
s = ::Clerk::OpenAPIClient.new(
bearer_auth: '<YOUR_BEARER_TOKEN_HERE>'
)
res = s.clients.get(client_id: 'cli_123456789')
unless res.client.nil?
# handle response
end| Parameter | Type | Required | Description |
|---|---|---|---|
client_id |
::String | ✔️ | Client ID. |
Crystalline::Nilable.new(Models::Operations::GetClientResponse)
| Error Type | Status Code | Content Type |
|---|---|---|
| Models::Errors::ClerkErrors | 400, 401, 404 | application/json |
| Errors::APIError | 4XX, 5XX | */* |