Class: Amocrm::Models::RoleCreateParams::Body

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/amocrm/models/role_create_params.rb

Defined Under Namespace

Classes: Rights

Instance Attribute Summary collapse

Instance Method Summary collapse

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(name:, request_id: nil, rights: nil) ⇒ Object

Parameters:



19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
# File 'lib/amocrm/models/role_create_params.rb', line 19

class Body < Amocrm::Internal::Type::BaseModel
  # @!attribute name
  #
  #   @return [String]
  required :name, String

  # @!attribute request_id
  #
  #   @return [String, nil]
  optional :request_id, String

  # @!attribute rights
  #
  #   @return [Amocrm::Models::RoleCreateParams::Body::Rights, nil]
  optional :rights, -> { Amocrm::RoleCreateParams::Body::Rights }

  # @!method initialize(name:, request_id: nil, rights: nil)
  #   @param name [String]
  #   @param request_id [String]
  #   @param rights [Amocrm::Models::RoleCreateParams::Body::Rights]

  # @see Amocrm::Models::RoleCreateParams::Body#rights
  class Rights < Amocrm::Internal::Type::BaseModel
    # @!attribute catalog_access
    #
    #   @return [Boolean, nil]
    optional :catalog_access, Amocrm::Internal::Type::Boolean

    # @!attribute companies
    #
    #   @return [Object, nil]
    optional :companies, Amocrm::Internal::Type::Unknown

    # @!attribute contacts
    #
    #   @return [Object, nil]
    optional :contacts, Amocrm::Internal::Type::Unknown

    # @!attribute group_id
    #
    #   @return [Integer, nil]
    optional :group_id, Integer, nil?: true

    # @!attribute is_active
    #
    #   @return [Boolean, nil]
    optional :is_active, Amocrm::Internal::Type::Boolean

    # @!attribute is_admin
    #
    #   @return [Boolean, nil]
    optional :is_admin, Amocrm::Internal::Type::Boolean

    # @!attribute is_free
    #
    #   @return [Boolean, nil]
    optional :is_free, Amocrm::Internal::Type::Boolean

    # @!attribute leads
    #
    #   @return [Object, nil]
    optional :leads, Amocrm::Internal::Type::Unknown

    # @!attribute mail_access
    #
    #   @return [Boolean, nil]
    optional :mail_access, Amocrm::Internal::Type::Boolean

    # @!attribute role_id
    #
    #   @return [Integer, nil]
    optional :role_id, Integer, nil?: true

    # @!attribute status_rights
    #
    #   @return [Array<Amocrm::Models::RoleCreateParams::Body::Rights::StatusRight>, nil]
    optional :status_rights,
             -> {
               Amocrm::Internal::Type::ArrayOf[Amocrm::RoleCreateParams::Body::Rights::StatusRight]
             },
             nil?: true

    # @!attribute tasks
    #
    #   @return [Object, nil]
    optional :tasks, Amocrm::Internal::Type::Unknown

    # @!method initialize(catalog_access: nil, companies: nil, contacts: nil, group_id: nil, is_active: nil, is_admin: nil, is_free: nil, leads: nil, mail_access: nil, role_id: nil, status_rights: nil, tasks: nil)
    #   @param catalog_access [Boolean]
    #   @param companies [Object]
    #   @param contacts [Object]
    #   @param group_id [Integer, nil]
    #   @param is_active [Boolean]
    #   @param is_admin [Boolean]
    #   @param is_free [Boolean]
    #   @param leads [Object]
    #   @param mail_access [Boolean]
    #   @param role_id [Integer, nil]
    #   @param status_rights [Array<Amocrm::Models::RoleCreateParams::Body::Rights::StatusRight>, nil]
    #   @param tasks [Object]

    class StatusRight < Amocrm::Internal::Type::BaseModel
      # @!attribute entity_type
      #
      #   @return [String, nil]
      optional :entity_type, String

      # @!attribute pipeline_id
      #
      #   @return [Integer, nil]
      optional :pipeline_id, Integer

      # @!attribute rights
      #
      #   @return [Object, nil]
      optional :rights, Amocrm::Internal::Type::Unknown

      # @!attribute status_id
      #
      #   @return [Integer, nil]
      optional :status_id, Integer

      # @!method initialize(entity_type: nil, pipeline_id: nil, rights: nil, status_id: nil)
      #   @param entity_type [String]
      #   @param pipeline_id [Integer]
      #   @param rights [Object]
      #   @param status_id [Integer]
    end
  end
end

Instance Attribute Details

#nameString

Returns:

  • (String)


23
# File 'lib/amocrm/models/role_create_params.rb', line 23

required :name, String

#request_idString?

Returns:

  • (String, nil)


28
# File 'lib/amocrm/models/role_create_params.rb', line 28

optional :request_id, String

#rightsAmocrm::Models::RoleCreateParams::Body::Rights?



33
# File 'lib/amocrm/models/role_create_params.rb', line 33

optional :rights, -> { Amocrm::RoleCreateParams::Body::Rights }