(embeds)
REST APIs for managing embeds
- get_embed_access_token - Get an embed access token for the current workspace.
- get_valid_embed_access_tokens - Get all valid embed access tokens for the current workspace.
- revoke_embed_access_token - Revoke an embed access EmbedToken.
Returns an embed access token for the current workspace. This can be used to authenticate access to externally embedded content. Filters can be applied allowing views to be filtered to things like particular customerIds.
from speakeasy_client_sdk_python import Speakeasy
from speakeasy_client_sdk_python.models import shared
s = Speakeasy(
security=shared.Security(
api_key="<YOUR_API_KEY_HERE>",
),
)
res = s.embeds.get_embed_access_token()
if res.embed_access_token_response is not None:
# handle response
pass
Parameter | Type | Required | Description |
---|---|---|---|
request |
operations.GetEmbedAccessTokenRequest | ✔️ | The request object to use for the request. |
retries |
Optional[utils.RetryConfig] | ➖ | Configuration to override the default retry behavior of the client. |
operations.GetEmbedAccessTokenResponse
Error Object | Status Code | Content Type |
---|---|---|
errors.SDKError | 4xx-5xx | / |
Get all valid embed access tokens for the current workspace.
from speakeasy_client_sdk_python import Speakeasy
from speakeasy_client_sdk_python.models import shared
s = Speakeasy(
security=shared.Security(
api_key="<YOUR_API_KEY_HERE>",
),
)
res = s.embeds.get_valid_embed_access_tokens()
if res.embed_tokens is not None:
# handle response
pass
Parameter | Type | Required | Description |
---|---|---|---|
retries |
Optional[utils.RetryConfig] | ➖ | Configuration to override the default retry behavior of the client. |
operations.GetValidEmbedAccessTokensResponse
Error Object | Status Code | Content Type |
---|---|---|
errors.SDKError | 4xx-5xx | / |
Revoke an embed access EmbedToken.
from speakeasy_client_sdk_python import Speakeasy
from speakeasy_client_sdk_python.models import shared
s = Speakeasy(
security=shared.Security(
api_key="<YOUR_API_KEY_HERE>",
),
)
res = s.embeds.revoke_embed_access_token(request={
"token_id": "<value>",
})
if res is not None:
# handle response
pass
Parameter | Type | Required | Description |
---|---|---|---|
request |
operations.RevokeEmbedAccessTokenRequest | ✔️ | The request object to use for the request. |
retries |
Optional[utils.RetryConfig] | ➖ | Configuration to override the default retry behavior of the client. |
operations.RevokeEmbedAccessTokenResponse
Error Object | Status Code | Content Type |
---|---|---|
errors.SDKError | 4xx-5xx | / |