Class: OpenAI::Models::Admin::Organization::UsageCodeInterpreterSessionsParams

Inherits:
Internal::Type::BaseModel show all
Extended by:
Internal::Type::RequestParameters::Converter
Includes:
Internal::Type::RequestParameters
Defined in:
lib/openai/models/admin/organization/usage_code_interpreter_sessions_params.rb

Overview

Defined Under Namespace

Modules: BucketWidth, GroupBy

Instance Attribute Summary collapse

Attributes included from Internal::Type::RequestParameters

#request_options

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Internal::Type::RequestParameters::Converter

dump_request

Methods included from Internal::Type::RequestParameters

included

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, 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, #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(start_time:, bucket_width: nil, end_time: nil, group_by: nil, limit: nil, page: nil, project_ids: nil, request_options: {}) ⇒ Object

Some parameter documentations has been truncated, see OpenAI::Models::Admin::Organization::UsageCodeInterpreterSessionsParams for more details.

Parameters:

  • start_time (Integer)

    Start time (Unix seconds) of the query time range, inclusive.

  • bucket_width (Symbol, OpenAI::Models::Admin::Organization::UsageCodeInterpreterSessionsParams::BucketWidth) (defaults to: nil)

    Width of each time bucket in response. Currently ‘1m`, `1h` and `1d` are support

  • end_time (Integer) (defaults to: nil)

    End time (Unix seconds) of the query time range, exclusive.

  • group_by (Array<Symbol, OpenAI::Models::Admin::Organization::UsageCodeInterpreterSessionsParams::GroupBy>) (defaults to: nil)

    Group the usage data by the specified fields. Support fields include ‘project_id

  • limit (Integer) (defaults to: nil)

    Specifies the number of buckets to return.

  • page (String) (defaults to: nil)

    A cursor for use in pagination. Corresponding to the ‘next_page` field from the

  • project_ids (Array<String>) (defaults to: nil)

    Return only usage for these projects.

  • request_options (OpenAI::RequestOptions, Hash{Symbol=>Object}) (defaults to: {})


# File 'lib/openai/models/admin/organization/usage_code_interpreter_sessions_params.rb', line 63

Instance Attribute Details

#bucket_widthSymbol, ...

Width of each time bucket in response. Currently ‘1m`, `1h` and `1d` are supported, default to `1d`.



23
24
# File 'lib/openai/models/admin/organization/usage_code_interpreter_sessions_params.rb', line 23

optional :bucket_width,
enum: -> { OpenAI::Admin::Organization::UsageCodeInterpreterSessionsParams::BucketWidth }

#end_timeInteger?

End time (Unix seconds) of the query time range, exclusive.

Returns:

  • (Integer, nil)


30
# File 'lib/openai/models/admin/organization/usage_code_interpreter_sessions_params.rb', line 30

optional :end_time, Integer

#group_byArray<Symbol, OpenAI::Models::Admin::Organization::UsageCodeInterpreterSessionsParams::GroupBy>?

Group the usage data by the specified fields. Support fields include ‘project_id`.



37
38
# File 'lib/openai/models/admin/organization/usage_code_interpreter_sessions_params.rb', line 37

optional :group_by,
-> { OpenAI::Internal::Type::ArrayOf[enum: OpenAI::Admin::Organization::UsageCodeInterpreterSessionsParams::GroupBy] }

#limitInteger?

Specifies the number of buckets to return.

  • ‘bucket_width=1d`: default: 7, max: 31

  • ‘bucket_width=1h`: default: 24, max: 168

  • ‘bucket_width=1m`: default: 60, max: 1440

Returns:

  • (Integer, nil)


48
# File 'lib/openai/models/admin/organization/usage_code_interpreter_sessions_params.rb', line 48

optional :limit, Integer

#pageString?

A cursor for use in pagination. Corresponding to the ‘next_page` field from the previous response.

Returns:

  • (String, nil)


55
# File 'lib/openai/models/admin/organization/usage_code_interpreter_sessions_params.rb', line 55

optional :page, String

#project_idsArray<String>?

Return only usage for these projects.

Returns:

  • (Array<String>, nil)


61
# File 'lib/openai/models/admin/organization/usage_code_interpreter_sessions_params.rb', line 61

optional :project_ids, OpenAI::Internal::Type::ArrayOf[String]

#start_timeInteger

Start time (Unix seconds) of the query time range, inclusive.

Returns:

  • (Integer)


16
# File 'lib/openai/models/admin/organization/usage_code_interpreter_sessions_params.rb', line 16

required :start_time, Integer

Class Method Details

.valuesArray<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/openai/models/admin/organization/usage_code_interpreter_sessions_params.rb', line 93