Class: OpenAI::Models::Beta::Agents::Vaults::CredentialAuthCreateParam::McpOauth

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/openai/models/beta/agents/vaults/credential_auth_create_param.rb,
sig/openai/models/beta/agents/vaults/credential_auth_create_param.rbs

Defined Under Namespace

Classes: Refresh

Instance Attribute Summary collapse

Attributes inherited from Internal::Type::BaseModel

#last_response

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], #_request_id, #_set_last_response, coerce, #deconstruct_keys, #deep_to_h, dump, #encode_with, fields, hash, #hash, inherited, #inspect, inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, coerce_with_error, dump, #dump, #inspect, inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(access_token:, mcp_server_url:, expires_at: nil, refresh: nil, type: :mcp_oauth) ⇒ Object

An OAuth credential for an HTTPS MCP destination.

Parameters:

  • access_token (String)

    A write-only OAuth access token; never returned by credential resources.

  • mcp_server_url (String)

    The HTTPS MCP server URL authorized by this credential.

  • expires_at (String, nil) (defaults to: nil)

    When the OAuth access token expires, as an RFC 3339 timestamp, if known.

  • refresh (OpenAI::Models::Beta::Agents::Vaults::CredentialAuthCreateParam::McpOauth::Refresh, nil) (defaults to: nil)

    Configuration for refreshing the access token of an MCP OAuth credential.

  • type (Symbol, :mcp_oauth) (defaults to: :mcp_oauth)

    The type of the object. Always mcp_oauth.



# File 'lib/openai/models/beta/agents/vaults/credential_auth_create_param.rb', line 55

Instance Attribute Details

#access_tokenString

A write-only OAuth access token; never returned by credential resources.

Parameters:

  • value (String)

Returns:

  • (String)


25
# File 'lib/openai/models/beta/agents/vaults/credential_auth_create_param.rb', line 25

required :access_token, String

#expires_atString?

When the OAuth access token expires, as an RFC 3339 timestamp, if known.

Parameters:

  • value (String, nil)

Returns:

  • (String, nil)


43
# File 'lib/openai/models/beta/agents/vaults/credential_auth_create_param.rb', line 43

optional :expires_at, String, nil?: true

#mcp_server_urlString

The HTTPS MCP server URL authorized by this credential.

Parameters:

  • value (String)

Returns:

  • (String)


31
# File 'lib/openai/models/beta/agents/vaults/credential_auth_create_param.rb', line 31

required :mcp_server_url, String

#refreshOpenAI::Models::Beta::Agents::Vaults::CredentialAuthCreateParam::McpOauth::Refresh?

Configuration for refreshing the access token of an MCP OAuth credential.

Parameters:

  • value (OpenAI::Beta::Agents::Vaults::CredentialAuthCreateParam::McpOauth::Refresh, nil)

Returns:



49
50
51
52
53
# File 'lib/openai/models/beta/agents/vaults/credential_auth_create_param.rb', line 49

optional(
  :refresh,
  -> { OpenAI::Beta::Agents::Vaults::CredentialAuthCreateParam::McpOauth::Refresh },
  nil?: true
)

#typeSymbol, :mcp_oauth

The type of the object. Always mcp_oauth.

Parameters:

  • value (:mcp_oauth)

Returns:

  • (Symbol, :mcp_oauth)


37
# File 'lib/openai/models/beta/agents/vaults/credential_auth_create_param.rb', line 37

required :type, const: :mcp_oauth

Instance Method Details

#to_hash{

Returns:

  • ({)


41
# File 'sig/openai/models/beta/agents/vaults/credential_auth_create_param.rbs', line 41

def to_hash: -> {