Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(api): OpenAPI spec update via Stainless API #172

Merged
merged 1 commit into from
Mar 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions src/cloudflare/types/zero_trust/access/access_apps.py
Original file line number Diff line number Diff line change
Expand Up @@ -242,6 +242,15 @@ class SaaSApplicationSaasAppAccessSamlSaasApp(BaseModel):
public_key: Optional[str] = None
"""The Access public certificate that will be used to verify your identity."""

saml_attribute_transform_jsonata: Optional[str] = None
"""
A [JSONata] (https://jsonata.org/) expression that transforms an application's
user identities into attribute assertions in the SAML response. The expression
can transform id, email, name, and groups values. It can also transform fields
listed in the saml_attributes or oidc_fields of the identity provider used to
authenticate. The output of this expression must be a JSON object.
"""

sp_entity_id: Optional[str] = None
"""A globally unique name for an identity or service provider."""

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -276,6 +276,15 @@ class SaaSApplicationSaasAppAccessSamlSaasApp(TypedDict, total=False):
public_key: str
"""The Access public certificate that will be used to verify your identity."""

saml_attribute_transform_jsonata: str
"""
A [JSONata] (https://jsonata.org/) expression that transforms an application's
user identities into attribute assertions in the SAML response. The expression
can transform id, email, name, and groups values. It can also transform fields
listed in the saml_attributes or oidc_fields of the identity provider used to
authenticate. The output of this expression must be a JSON object.
"""

sp_entity_id: str
"""A globally unique name for an identity or service provider."""

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -276,6 +276,15 @@ class SaaSApplicationSaasAppAccessSamlSaasApp(TypedDict, total=False):
public_key: str
"""The Access public certificate that will be used to verify your identity."""

saml_attribute_transform_jsonata: str
"""
A [JSONata] (https://jsonata.org/) expression that transforms an application's
user identities into attribute assertions in the SAML response. The expression
can transform id, email, name, and groups values. It can also transform fields
listed in the saml_attributes or oidc_fields of the identity provider used to
authenticate. The output of this expression must be a JSON object.
"""

sp_entity_id: str
"""A globally unique name for an identity or service provider."""

Expand Down
4 changes: 4 additions & 0 deletions tests/api_resources/zero_trust/access/test_applications.py
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,7 @@ def test_method_create_with_all_params_overload_2(self, client: Cloudflare) -> N
"name_id_format": "id",
"name_id_transform_jsonata": "$substringBefore(email, '@') & '+sandbox@' & $substringAfter(email, '@')",
"public_key": "example unique name",
"saml_attribute_transform_jsonata": "$ ~>| groups | {'group_name': name} |",
"sp_entity_id": "example unique name",
"sso_endpoint": "https://example.cloudflareaccess.com/cdn-cgi/access/sso/saml/b3f58a2b414e0b51d45c8c2af26fccca0e27c63763c426fa52f98dcf0b3b3bfd",
},
Expand Down Expand Up @@ -893,6 +894,7 @@ def test_method_update_with_all_params_overload_2(self, client: Cloudflare) -> N
"name_id_format": "id",
"name_id_transform_jsonata": "$substringBefore(email, '@') & '+sandbox@' & $substringAfter(email, '@')",
"public_key": "example unique name",
"saml_attribute_transform_jsonata": "$ ~>| groups | {'group_name': name} |",
"sp_entity_id": "example unique name",
"sso_endpoint": "https://example.cloudflareaccess.com/cdn-cgi/access/sso/saml/b3f58a2b414e0b51d45c8c2af26fccca0e27c63763c426fa52f98dcf0b3b3bfd",
},
Expand Down Expand Up @@ -1911,6 +1913,7 @@ async def test_method_create_with_all_params_overload_2(self, async_client: Asyn
"name_id_format": "id",
"name_id_transform_jsonata": "$substringBefore(email, '@') & '+sandbox@' & $substringAfter(email, '@')",
"public_key": "example unique name",
"saml_attribute_transform_jsonata": "$ ~>| groups | {'group_name': name} |",
"sp_entity_id": "example unique name",
"sso_endpoint": "https://example.cloudflareaccess.com/cdn-cgi/access/sso/saml/b3f58a2b414e0b51d45c8c2af26fccca0e27c63763c426fa52f98dcf0b3b3bfd",
},
Expand Down Expand Up @@ -2631,6 +2634,7 @@ async def test_method_update_with_all_params_overload_2(self, async_client: Asyn
"name_id_format": "id",
"name_id_transform_jsonata": "$substringBefore(email, '@') & '+sandbox@' & $substringAfter(email, '@')",
"public_key": "example unique name",
"saml_attribute_transform_jsonata": "$ ~>| groups | {'group_name': name} |",
"sp_entity_id": "example unique name",
"sso_endpoint": "https://example.cloudflareaccess.com/cdn-cgi/access/sso/saml/b3f58a2b414e0b51d45c8c2af26fccca0e27c63763c426fa52f98dcf0b3b3bfd",
},
Expand Down