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

# Add or update relationships for an organization

> Add or update a list of entity relationships for an organization. This will not modify any relationships (ie officials) from other (non-manual) sources. Relationships added with this operation can only be updated the same way.



## OpenAPI

````yaml /specs/fc-kyb-bundled_generated.yaml put /v2/organizations/{entityId}/relationships
openapi: 3.0.3
info:
  title: KYB V2 API
  version: '2.0'
  description: >-
    This is the MVP for Phase 1 APIs for native v2 KYB. Currently in
    development, changes to the structure can occur
  contact:
    name: FrankieOne
    url: https://www.frankieone.com/
    email: help@frankieone.com
servers:
  - url: https://api.uat.frankie.one
    description: UAT Environment API Base URL
  - url: https://api.frankie.one
    description: Production API Base URL
security:
  - Api-Key: []
tags:
  - name: Organizations
    description: Api calls related to Organizations
  - name: Organization Workflows
    description: Manage workflows and executions for organizations
  - name: Hosted URL
    description: Api calls related to Hosted URL
  - name: Organization Relationships
    description: Manage relationships for organizations
  - name: Organization Addresses
    description: Manage addresses for organizations
  - name: Organization Custom Attributes
    description: Manage custom attributes for organizations
  - name: Organization Monitoring
    description: Manage AML monitoring for organizations
  - name: Organization Results
    description: Manage results for organizations
paths:
  /v2/organizations/{entityId}/relationships:
    parameters:
      - $ref: '#/components/parameters/entityId'
    put:
      tags:
        - Organization Relationships
      summary: Add or update relationships for an organization
      description: >-
        Add or update a list of entity relationships for an organization. This
        will not modify any relationships (ie officials) from other (non-manual)
        sources. Relationships added with this operation can only be updated the
        same way.
      operationId: addOrganizationRelationships
      parameters:
        - $ref: '#/components/parameters/Api-Key'
        - $ref: '#/components/parameters/X-Frankie-CustomerID'
        - $ref: '#/components/parameters/X-Frankie-CustomerChildID'
        - $ref: '#/components/parameters/X-Frankie-Channel'
        - $ref: '#/components/parameters/X-Frankie-Username'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Add-Entity-Relationships-Request'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Entity-Relationships-Response'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '502':
          description: Bad Gateway
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '503':
          description: Service Unavailable
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      security:
        - Api-Key: []
        - jwt:
            - kyb:api
components:
  parameters:
    entityId:
      name: entityId
      in: path
      schema:
        type: string
      description: Unique FrankieOne identifier for an entity
      required: true
    Api-Key:
      name: api_key
      in: header
      schema:
        type: string
        example: 245c765b124a098d09ef8765....
      description: Your API key provided by FrankieOne
      required: true
    X-Frankie-CustomerID:
      name: X-Frankie-CustomerID
      in: header
      required: true
      schema:
        type: string
        example: 12345678-1234-1234-1234-123456789012
      description: Your Customer ID provided by FrankieOne
    X-Frankie-CustomerChildID:
      name: X-Frankie-CustomerChildID
      in: header
      required: false
      schema:
        type: string
        example: 87654321-4321-4321-4321-210987654321
      description: Your Customer Child ID provided by FrankieOne
    X-Frankie-Channel:
      name: X-Frankie-Channel
      in: header
      required: false
      schema:
        type: string
      description: >-
        Open string that can be used to define the "channel" the request comes
        in from. It can potentially be used in routing and risk calculations
        upon request. Default values that can be used are:  api portal smartui
        Any alphanumeric string is supported though. Anything over 64 characters
        will be truncated.
    X-Frankie-Username:
      name: X-Frankie-Username
      in: header
      description: Username provided by API caller
      required: false
      schema:
        type: string
        example: fred.flintstone@frankieone.com
  schemas:
    Add-Entity-Relationships-Request:
      type: object
      description: List of entities and their relationships with an organization
      properties:
        entityRelationships:
          description: >-
            List of entities and their relationships that should be added or
            updated, or have been requested, for an organization. These do not
            include or affect any relationships from for example ownership
            reports.
          type: array
          items:
            $ref: '#/components/schemas/Entity-Relationship'
    Entity-Relationships-Response:
      type: object
      required:
        - requestId
      description: List of entities and their relationships with an organization
      properties:
        requestId:
          $ref: '#/components/schemas/Request-ID'
        entityRelationships:
          description: List of entities and their relationships with an organization
          type: array
          items:
            $ref: '#/components/schemas/Entity-Relationship'
    Error:
      type: object
      x-examples:
        '400':
          requestId: 0123456789ABCDEFGHIJKLMNOP
          errorCode: API-0400
          errorMsg: Parsing credentials from "<invalid>" failed, because invalid.
          httpStatusCode: 400
        '401':
          requestId: 0123456789ABCDEFGHIJKLMNOP
          errorCode: API-0401
          errorMsg: Unauthenticated due to invalid credentials.
          httpStatusCode: 401
        '409':
          requestId: 0123456789ABCDEFGHIJKLMNOP
          errorCode: API-0409
          errorMsg: Conflict.
          httpStatusCode: 409
      allOf:
        - $ref: '#/components/schemas/Error-Base'
        - type: object
          properties:
            requestId:
              $ref: '#/components/schemas/Request-ID'
    Entity-Relationship:
      type: object
      required:
        - entity
        - relationships
      description: Relationships between one entity and an organization
      properties:
        entity:
          $ref: '#/components/schemas/Relationship-Entity'
        relationships:
          description: List of relationships between the entity and an organization
          type: array
          minItems: 1
          items:
            $ref: '#/components/schemas/Relationship'
    Request-ID:
      type: string
      example: 01HN9XHZN6MGXM9JXG50K59Q85
      description: The unique request identifier for the API call made.
    Error-Base:
      type: object
      properties:
        errorCode:
          type: string
        errorMsg:
          type: string
        details:
          type: array
          items:
            $ref: '#/components/schemas/Issue'
    Relationship-Entity:
      type: object
      required:
        - entityId
      description: An entity that a list of organization relationships apply to.
      properties:
        entityId:
          $ref: '#/components/schemas/Relationship-Entity-ID'
        entityType:
          $ref: '#/components/schemas/Relationship-Entity-Type'
    Relationship:
      type: object
      required:
        - type
        - role
      description: One relationship
      properties:
        type:
          description: >-
            The type of the relationship. Currently only "OFFICIAL" is
            supported.
          type: string
          enum:
            - OFFICIAL
        role:
          $ref: '#/components/schemas/Relationship-Role'
        sourceId:
          type: string
          readOnly: true
          description: >-
            This is a link to an informationSource object in the
            informationSources map. For relationships this will be very basic
            and just contains the creation date, and a provider set to "MANUAL".
    Issue:
      type: object
      properties:
        issue:
          type: string
          description: Description of the issue.
        issueLocation:
          type: string
          description: The location or context where the issue was identified.
        issueType:
          type: string
          description: The type or category of the issue.
    Relationship-Entity-ID:
      type: string
      description: >-
        Entity ID of "child" entity that is has an association with the target
        entity.
      example: 3fa85f64-5717-4562-b3fc-2c963f66afa6
    Relationship-Entity-Type:
      type: string
      enum:
        - INDIVIDUAL
        - ORGANIZATION
      description: >-
        Type of entity within Frankie. This can either be "INDIVIDUAL" or
        "ORGANIZATION".  The "UNKNOWN" type is not supported in this context.
    Relationship-Role:
      type: object
      required:
        - code
      description: >-
        The role that is represented by the relationship. '''code''' is the
        normalized code for the role.
      properties:
        code:
          description: Short standard code or normalized representation of the relationship
          type: string
          example: DR
        description:
          description: A more descriptive title corresponding to the relationship code
          type: string
          example: Director
  securitySchemes:
    Api-Key:
      type: apiKey
      in: header
      name: api_key
      description: ''
    jwt:
      type: http
      scheme: bearer
      bearerFormat: JWT

````