> ## Documentation Index
> Fetch the complete documentation index at: https://developers.portao3.com.br/llms.txt
> Use this file to discover all available pages before exploring further.

# /realms/{realmId}/organizations/{organizationId}



## OpenAPI

````yaml /api-reference/identity.openapi.json patch /realms/{realmId}/organizations/{organizationId}
openapi: 3.0.3
info:
  title: Identity
  version: 1.0.0
  description: >-
    Portão 3 identity API. Generated by tools/openapi from code (routes +
    security) and the hand-written spec (request/response bodies). 5 app groups
    run without the identity authorizer; publicPatterns is a best-effort subset.
    Confidence tiers: generated:typed=34 copied:manual=4 unknown=108.
servers:
  - url: https://api.identity.v2.portao3.com.br/
    description: production
  - url: https://api.identity.dev.3pers.com.br/
    description: development
security:
  - bearerAuth: []
tags:
  - name: Authentication
  - name: Current User
  - name: Custom Fields
  - name: API Clients
  - name: Users
  - name: Organizations
  - name: Realms
  - name: Feature Flags
  - name: Global Config
  - name: Push
  - name: Support
  - name: User Onboarding
  - name: Internal
paths:
  /realms/{realmId}/organizations/{organizationId}:
    patch:
      tags:
        - Organizations
      summary: /realms/{realmId}/organizations/{organizationId}
      operationId: patchRealmsByRealmIdOrganizationsByOrganizationId
      parameters:
        - name: realmId
          in: path
          required: true
          schema:
            type: string
        - name: organizationId
          in: path
          required: true
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                nationality:
                  type: string
                  enum:
                    - AD
                    - AE
                    - AF
                    - AG
                    - AI
                    - AL
                    - AM
                    - AO
                    - AQ
                    - AR
                    - AS
                    - AT
                    - AU
                    - AW
                    - AX
                    - AZ
                    - BA
                    - BB
                    - BD
                    - BE
                    - BF
                    - BG
                    - BH
                    - BI
                    - BJ
                    - BL
                    - BM
                    - BN
                    - BO
                    - BQ
                    - BR
                    - BS
                    - BT
                    - BV
                    - BW
                    - BY
                    - BZ
                    - CA
                    - CC
                    - CD
                    - CF
                    - CG
                    - CH
                    - CI
                    - CK
                    - CL
                    - CM
                    - CN
                    - CO
                    - CR
                    - CU
                    - CV
                    - CW
                    - CX
                    - CY
                    - CZ
                    - DE
                    - DJ
                    - DK
                    - DM
                    - DO
                    - DZ
                    - EC
                    - EE
                    - EG
                    - EH
                    - ER
                    - ES
                    - ET
                    - FI
                    - FJ
                    - FK
                    - FM
                    - FO
                    - FR
                    - GA
                    - GB
                    - GD
                    - GE
                    - GF
                    - GG
                    - GH
                    - GI
                    - GL
                    - GM
                    - GN
                    - GP
                    - GQ
                    - GR
                    - GS
                    - GT
                    - GU
                    - GW
                    - GY
                    - HK
                    - HM
                    - HN
                    - HR
                    - HT
                    - HU
                    - ID
                    - IE
                    - IL
                    - IM
                    - IN
                    - IO
                    - IQ
                    - IR
                    - IS
                    - IT
                    - JE
                    - JM
                    - JO
                    - JP
                    - KE
                    - KG
                    - KH
                    - KI
                    - KM
                    - KN
                    - KP
                    - KR
                    - KW
                    - KY
                    - KZ
                    - LA
                    - LB
                    - LC
                    - LI
                    - LK
                    - LR
                    - LS
                    - LT
                    - LU
                    - LV
                    - LY
                    - MA
                    - MC
                    - MD
                    - ME
                    - MF
                    - MG
                    - MH
                    - MK
                    - ML
                    - MM
                    - MN
                    - MO
                    - MP
                    - MQ
                    - MR
                    - MS
                    - MT
                    - MU
                    - MV
                    - MW
                    - MX
                    - MY
                    - MZ
                    - NA
                    - NC
                    - NE
                    - NF
                    - NG
                    - NI
                    - NL
                    - 'NO'
                    - NP
                    - NR
                    - NU
                    - NZ
                    - OM
                    - PA
                    - PE
                    - PF
                    - PG
                    - PH
                    - PK
                    - PL
                    - PM
                    - PN
                    - PR
                    - PS
                    - PT
                    - PW
                    - PY
                    - QA
                    - RE
                    - RO
                    - RS
                    - RU
                    - RW
                    - SA
                    - SB
                    - SC
                    - SD
                    - SE
                    - SG
                    - SH
                    - SI
                    - SJ
                    - SK
                    - SL
                    - SM
                    - SN
                    - SO
                    - SR
                    - SS
                    - ST
                    - SV
                    - SX
                    - SY
                    - SZ
                    - TC
                    - TD
                    - TF
                    - TG
                    - TH
                    - TJ
                    - TK
                    - TL
                    - TM
                    - TN
                    - TO
                    - TR
                    - TT
                    - TV
                    - TW
                    - TZ
                    - UA
                    - UG
                    - UM
                    - US
                    - UY
                    - UZ
                    - VA
                    - VC
                    - VE
                    - VG
                    - VI
                    - VN
                    - VU
                    - WF
                    - WS
                    - YE
                    - YT
                    - ZA
                    - ZM
                    - ZW
                currency:
                  type: string
                  enum:
                    - '104'
                    - '108'
                    - '116'
                    - '124'
                    - '132'
                    - '136'
                    - '144'
                    - '152'
                    - '156'
                    - '170'
                    - '174'
                    - '188'
                    - '191'
                    - '192'
                    - '203'
                    - '208'
                    - '214'
                    - '222'
                    - '230'
                    - '232'
                    - '238'
                    - '242'
                    - '262'
                    - '270'
                    - '292'
                    - '320'
                    - '324'
                    - '328'
                    - '332'
                    - '340'
                    - '344'
                    - '348'
                    - '352'
                    - '356'
                    - '360'
                    - '364'
                    - '368'
                    - '376'
                    - '388'
                    - '392'
                    - '398'
                    - '400'
                    - '404'
                    - '408'
                    - '410'
                    - '414'
                    - '417'
                    - '418'
                    - '422'
                    - '426'
                    - '430'
                    - '434'
                    - '446'
                    - '454'
                    - '458'
                    - '462'
                    - '478'
                    - '480'
                    - '484'
                    - '496'
                    - '498'
                    - '504'
                    - '512'
                    - '516'
                    - '524'
                    - '532'
                    - '533'
                    - '548'
                    - '554'
                    - '558'
                    - '566'
                    - '578'
                    - '586'
                    - '590'
                    - '598'
                    - '600'
                    - '604'
                    - '608'
                    - '634'
                    - '643'
                    - '646'
                    - '654'
                    - '678'
                    - '682'
                    - '690'
                    - '694'
                    - '702'
                    - '704'
                    - '706'
                    - '710'
                    - '728'
                    - '748'
                    - '752'
                    - '756'
                    - '760'
                    - '764'
                    - '776'
                    - '780'
                    - '784'
                    - '788'
                    - '800'
                    - '807'
                    - '818'
                    - '826'
                    - '834'
                    - '840'
                    - '858'
                    - '860'
                    - '882'
                    - '886'
                    - '901'
                    - '931'
                    - '932'
                    - '934'
                    - '936'
                    - '937'
                    - '938'
                    - '940'
                    - '941'
                    - '943'
                    - '944'
                    - '946'
                    - '947'
                    - '948'
                    - '949'
                    - '950'
                    - '951'
                    - '952'
                    - '953'
                    - '960'
                    - '965'
                    - '967'
                    - '968'
                    - '969'
                    - '970'
                    - '972'
                    - '974'
                    - '975'
                    - '976'
                    - '977'
                    - '978'
                    - '979'
                    - '980'
                    - '981'
                    - '984'
                    - '985'
                    - '986'
                    - '990'
                    - '994'
                    - '997'
                    - '036'
                    - '090'
                    - '064'
                    - '096'
                    - '072'
                    - '068'
                    - '060'
                    - '084'
                    - '052'
                    - '050'
                    - '048'
                    - '044'
                    - '051'
                    - '012'
                    - '032'
                    - '008'
                legalName:
                  type: string
                  minLength: 1
                tradingName:
                  type: string
                foundingDate:
                  type: string
                  minLength: 1
                mainActivity:
                  type: string
                  minLength: 1
                taxationRegime:
                  type: string
                  nullable: true
                descriptionTaxationRegime:
                  type: string
                  nullable: true
                email:
                  type: string
                  format: email
                  pattern: >-
                    ^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$
                ddi:
                  type: string
                  minLength: 1
                phoneNumber:
                  type: string
                  minLength: 1
                businessType:
                  type: string
                  enum:
                    - LTDA
                    - SA
                    - EIRELI
                    - ME
                    - MEI
                    - EI
                    - SS
                    - SLU
                    - OUTRO
                shareholders:
                  minItems: 1
                  type: array
                  items:
                    type: object
                    properties:
                      address:
                        default: {}
                        type: object
                        properties:
                          city:
                            type: string
                            minLength: 1
                            maxLength: 50
                          complement:
                            type: string
                            maxLength: 50
                          neighborhood:
                            type: string
                            minLength: 1
                            maxLength: 100
                          number:
                            type: string
                            minLength: 1
                          postalCode:
                            type: string
                            minLength: 1
                          state:
                            type: string
                            enum:
                              - AC
                              - AL
                              - AP
                              - AM
                              - BA
                              - CE
                              - ES
                              - GO
                              - MA
                              - MT
                              - MS
                              - MG
                              - PA
                              - PB
                              - PR
                              - PE
                              - PI
                              - RJ
                              - RN
                              - RS
                              - RO
                              - RR
                              - SC
                              - SP
                              - SE
                              - TO
                              - DF
                          street:
                            type: string
                            minLength: 1
                            maxLength: 100
                        required:
                          - city
                          - neighborhood
                          - number
                          - postalCode
                          - state
                          - street
                      birthDate:
                        type: string
                        nullable: true
                      document:
                        type: string
                        minLength: 1
                      email:
                        anyOf:
                          - type: string
                            format: email
                            pattern: >-
                              ^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$
                          - type: string
                            enum:
                              - ''
                      firstName:
                        type: string
                      lastName:
                        type: string
                      legalName:
                        type: string
                      tradingName:
                        type: string
                      mainActivity:
                        type: string
                      foundingDate:
                        type: string
                      motherName:
                        type: string
                      ddi:
                        type: string
                        minLength: 1
                      phoneNumber:
                        type: string
                        minLength: 1
                      type:
                        type: string
                        enum:
                          - LEGAL_REPRESENTATIVE
                          - PROXYHOLDER
                          - PARTNER
                    required:
                      - document
                      - ddi
                      - phoneNumber
                      - type
                municipalDocument:
                  type: string
                stateDocument:
                  type: string
                address:
                  default: {}
                  type: object
                  properties:
                    city:
                      type: string
                      minLength: 1
                      maxLength: 50
                    neighborhood:
                      type: string
                      minLength: 1
                      maxLength: 100
                    number:
                      type: string
                      minLength: 1
                    state:
                      type: string
                      enum:
                        - AC
                        - AL
                        - AP
                        - AM
                        - BA
                        - CE
                        - ES
                        - GO
                        - MA
                        - MT
                        - MS
                        - MG
                        - PA
                        - PB
                        - PR
                        - PE
                        - PI
                        - RJ
                        - RN
                        - RS
                        - RO
                        - RR
                        - SC
                        - SP
                        - SE
                        - TO
                        - DF
                    street:
                      type: string
                      minLength: 1
                      maxLength: 100
                    postalCode:
                      type: string
                      minLength: 1
                    complement:
                      type: string
                      maxLength: 50
                    stateCode:
                      type: number
                      minimum: 0
                      exclusiveMinimum: true
                    cityCode:
                      type: number
                      minimum: 0
                      exclusiveMinimum: true
                  required:
                    - city
                    - neighborhood
                    - number
                    - state
                    - street
                    - postalCode
                walletProduct:
                  type: string
                  enum:
                    - NORMAL
                    - SUPER
                    - BLACK
                    - RETRANSFER
                    - PRODUCT_08
                    - PRODUCT_09
              required:
                - nationality
                - currency
                - legalName
                - foundingDate
                - mainActivity
                - email
                - ddi
                - phoneNumber
                - businessType
                - shareholders
      responses:
        default:
          description: Undocumented response (no code type, no existing spec).
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````