Class: Anthropic::Resources::UserProfiles::ActionURLs
- Inherits:
-
Object
- Object
- Anthropic::Resources::UserProfiles::ActionURLs
- Defined in:
- lib/anthropic/resources/user_profiles/action_urls.rb,
sig/anthropic/resources/user_profiles/action_urls.rbs
Instance Method Summary collapse
-
#create(user_profile_id, action:, workspace_id: nil, request_options: {}) ⇒ Anthropic::Models::UserProfiles::UserProfileActionURL
Create a link that sends the profile's end customer to the Verification Portal.
-
#initialize(client:) ⇒ ActionURLs
constructor
private
A new instance of ActionURLs.
Constructor Details
#initialize(client:) ⇒ ActionURLs
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of ActionURLs.
48 49 50 |
# File 'lib/anthropic/resources/user_profiles/action_urls.rb', line 48 def initialize(client:) @client = client end |
Instance Method Details
#create(user_profile_id, action:, workspace_id: nil, request_options: {}) ⇒ Anthropic::Models::UserProfiles::UserProfileActionURL
Create a link that sends the profile's end customer to the Verification Portal.
See Send an end customer a link to the Verification Portal for when to create the link and what the end customer sees.
Some parameter documentations has been truncated, see Models::UserProfiles::ActionURLCreateParams for more details.
29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 |
# File 'lib/anthropic/resources/user_profiles/action_urls.rb', line 29 def create(user_profile_id, params) parsed, = Anthropic::UserProfiles::ActionURLCreateParams.dump_request(params) header_params = {workspace_id: "anthropic-workspace-id"} @client.request( span_name: Anthropic::Internal::Tracing::SpanName::USER_PROFILES_ACTION_URLS_CREATE, span_attributes: {"anthropic.user_profile.id" => user_profile_id}, span_route: "/v1/user_profiles/{user_profile_id}/action_urls", method: :post, path: ["v1/user_profiles/%1$s/action_urls", user_profile_id], headers: parsed.slice(*header_params.keys).transform_keys(header_params), body: parsed.except(*header_params.keys), model: Anthropic::UserProfiles::UserProfileActionURL, options: ) end |