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

# Update a partnership deal



## OpenAPI

````yaml /partner-openapi.json patch /partner/{partnershipId}/deals/{dealId}
openapi: 3.1.0
info:
  title: Journeybee Partner API
  description: Partner-facing REST API for the Journeybee PRM platform.
  version: 1.0.0
servers:
  - url: https://api.journeybee.io/v1
    description: Production
security:
  - apiKey: []
tags:
  - name: Partner
    description: Partner-facing API endpoints — used only by the partner spec
paths:
  /partner/{partnershipId}/deals/{dealId}:
    patch:
      tags:
        - Partner
      summary: Update a partnership deal
      operationId: updatePartnerDeal
      parameters:
        - schema:
            type: string
            format: uuid
            pattern: >-
              ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
          in: path
          name: partnershipId
          required: true
        - schema:
            type: string
            format: uuid
            pattern: >-
              ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
          in: path
          name: dealId
          required: true
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                fields:
                  type: object
                  properties:
                    stage_id:
                      type: string
                    label:
                      type: string
                    expiration_date:
                      anyOf:
                        - type: string
                          format: date-time
                          pattern: >-
                            ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
                        - type: 'null'
                    custom_field_values:
                      type: array
                      items:
                        type: object
                        properties:
                          custom_field_id:
                            type: string
                          custom_field_value_id:
                            type: string
                          value:
                            type: object
                            properties:
                              text:
                                description: Value for text/url/email/phone fields
                                anyOf:
                                  - type: string
                                  - type: 'null'
                              number:
                                description: Value for number fields
                                anyOf:
                                  - anyOf:
                                      - type: number
                                      - type: string
                                  - type: 'null'
                              date:
                                description: Value for date fields (ISO 8601 date string)
                                anyOf:
                                  - type: string
                                  - type: 'null'
                              boolean:
                                description: Value for checkbox fields
                                anyOf:
                                  - anyOf:
                                      - type: boolean
                                      - type: string
                                  - type: 'null'
                              select:
                                description: Option ID for single-select fields
                                anyOf:
                                  - type: number
                                  - type: 'null'
                              multi_select:
                                description: Option IDs for multi-select fields
                                anyOf:
                                  - type: array
                                    items:
                                      type: number
                                  - type: 'null'
                            additionalProperties: false
                            description: >-
                              Custom field value. Set the key matching the field
                              type: text (text/url/email/phone), number, date,
                              boolean (checkbox), select (option ID), or
                              multi_select (array of option IDs).
                        required:
                          - custom_field_id
                          - value
                        additionalProperties: false
                    partner_custom_field_values:
                      type: array
                      items:
                        type: object
                        properties:
                          custom_field_id:
                            type: string
                          custom_field_value_id:
                            type: string
                          lead_deal_id:
                            type: string
                          value:
                            anyOf:
                              - type: object
                                properties:
                                  text:
                                    description: Value for text/url/email/phone fields
                                    anyOf:
                                      - type: string
                                      - type: 'null'
                                  number:
                                    description: Value for number fields
                                    anyOf:
                                      - anyOf:
                                          - type: number
                                          - type: string
                                      - type: 'null'
                                  date:
                                    description: >-
                                      Value for date fields (ISO 8601 date
                                      string)
                                    anyOf:
                                      - type: string
                                      - type: 'null'
                                  boolean:
                                    description: Value for checkbox fields
                                    anyOf:
                                      - anyOf:
                                          - type: boolean
                                          - type: string
                                      - type: 'null'
                                  select:
                                    description: Option ID for single-select fields
                                    anyOf:
                                      - type: number
                                      - type: 'null'
                                  multi_select:
                                    description: Option IDs for multi-select fields
                                    anyOf:
                                      - type: array
                                        items:
                                          type: number
                                      - type: 'null'
                                additionalProperties: false
                                description: >-
                                  Custom field value. Set the key matching the
                                  field type: text (text/url/email/phone),
                                  number, date, boolean (checkbox), select
                                  (option ID), or multi_select (array of option
                                  IDs).
                              - type: 'null'
                        required:
                          - custom_field_id
                          - lead_deal_id
                          - value
                        additionalProperties: false
                    tag:
                      type: object
                      properties:
                        id:
                          type: string
                        label:
                          type: string
                        background_color:
                          type: string
                        text_color:
                          anyOf:
                            - type: string
                            - type: 'null'
                        added:
                          type: boolean
                        removed:
                          type: boolean
                      additionalProperties: false
                  additionalProperties: false
              additionalProperties: false
      responses:
        '200':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  uuid:
                    type: string
                  created_at:
                    type: string
                  updated_at:
                    type: string
                  deal_value:
                    type: number
                  total_commission_occurrences:
                    type: number
                  lead_id:
                    type: string
                  total_commission_value:
                    anyOf:
                      - type: number
                      - type: 'null'
                  stage_id:
                    anyOf:
                      - type: string
                      - type: 'null'
                  label:
                    type: string
                  created_by_user_id:
                    anyOf:
                      - type: string
                      - type: 'null'
                  expiration_date:
                    anyOf:
                      - type: string
                      - type: 'null'
                  expired_at:
                    anyOf:
                      - type: string
                      - type: 'null'
                  currency_code:
                    anyOf:
                      - type: string
                      - type: 'null'
                  stage:
                    anyOf:
                      - type: object
                        properties:
                          id:
                            type: string
                          label:
                            anyOf:
                              - type: string
                              - type: 'null'
                          series:
                            anyOf:
                              - type: number
                              - type: 'null'
                          phase:
                            anyOf:
                              - type: string
                                enum:
                                  - new
                                  - in_progress
                                  - won
                                  - lost
                                  - expired
                                  - on_hold
                              - type: 'null'
                        required:
                          - id
                          - label
                          - series
                          - phase
                        additionalProperties: false
                      - type: 'null'
                  created_by_user_first_name:
                    anyOf:
                      - anyOf:
                          - type: string
                          - type: 'null'
                      - type: 'null'
                  created_by_user_last_name:
                    anyOf:
                      - anyOf:
                          - type: string
                          - type: 'null'
                      - type: 'null'
                  created_by_user_email:
                    anyOf:
                      - type: string
                      - type: 'null'
                  created_by_user_profile_image_id:
                    anyOf:
                      - type: number
                      - type: 'null'
                  created_by_user_profile_image_uuid:
                    anyOf:
                      - type: string
                      - type: 'null'
                  lead_company_name:
                    anyOf:
                      - type: string
                      - type: 'null'
                  lead_first_name:
                    anyOf:
                      - type: string
                      - type: 'null'
                  lead_last_name:
                    anyOf:
                      - type: string
                      - type: 'null'
                  lead_email:
                    anyOf:
                      - type: string
                      - type: 'null'
                  lead_phone_number:
                    anyOf:
                      - type: string
                      - type: 'null'
                  lead_direction:
                    anyOf:
                      - type: string
                        enum:
                          - sent
                          - received
                      - type: 'null'
                  lead_status:
                    type: string
                    enum:
                      - new
                      - converted
                      - rejected
                  lead_campaign_id:
                    anyOf:
                      - type: string
                      - type: 'null'
                  campaign_title:
                    anyOf:
                      - anyOf:
                          - type: string
                          - type: 'null'
                      - type: 'null'
                  partnership:
                    anyOf:
                      - type: object
                        properties:
                          id:
                            type: string
                          uuid:
                            type: string
                          name:
                            anyOf:
                              - type: string
                              - type: 'null'
                          partner_type:
                            type: string
                            enum:
                              - referral
                              - reseller
                              - distributor
                          logo_square_id:
                            anyOf:
                              - type: number
                              - type: 'null'
                          logo_square_uuid:
                            anyOf:
                              - type: string
                              - type: 'null'
                          partnership_distributors_id:
                            anyOf:
                              - type: string
                              - type: 'null'
                          distributor_name:
                            anyOf:
                              - type: string
                              - type: 'null'
                          distributor_logo_square_id:
                            anyOf:
                              - type: number
                              - type: 'null'
                          distributor_logo_square_uuid:
                            anyOf:
                              - type: string
                              - type: 'null'
                        required:
                          - id
                          - uuid
                          - name
                          - partner_type
                          - logo_square_id
                          - logo_square_uuid
                          - partnership_distributors_id
                          - distributor_name
                          - distributor_logo_square_id
                          - distributor_logo_square_uuid
                        additionalProperties: false
                      - type: 'null'
                  tags:
                    type: array
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                        label:
                          type: string
                        background_color:
                          type: string
                        text_color:
                          anyOf:
                            - type: string
                            - type: 'null'
                      required:
                        - id
                        - label
                        - background_color
                        - text_color
                      additionalProperties: false
                  assigned_users:
                    type: array
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                        first_name:
                          anyOf:
                            - type: string
                            - type: 'null'
                        last_name:
                          anyOf:
                            - type: string
                            - type: 'null'
                        email:
                          type: string
                        profile_image_id:
                          anyOf:
                            - type: number
                            - type: 'null'
                        profile_image_uuid:
                          anyOf:
                            - type: string
                            - type: 'null'
                      required:
                        - id
                        - first_name
                        - last_name
                        - email
                        - profile_image_id
                        - profile_image_uuid
                      additionalProperties: false
                  assigned_contacts:
                    type: array
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                        first_name:
                          anyOf:
                            - type: string
                            - type: 'null'
                        last_name:
                          anyOf:
                            - type: string
                            - type: 'null'
                        email:
                          type: string
                        profile_image_id:
                          anyOf:
                            - anyOf:
                                - type: number
                                - type: 'null'
                            - type: 'null'
                        profile_image_uuid:
                          anyOf:
                            - type: string
                            - type: 'null'
                      required:
                        - id
                        - first_name
                        - last_name
                        - email
                        - profile_image_id
                        - profile_image_uuid
                      additionalProperties: false
                  custom_fields:
                    type: array
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                        label:
                          type: string
                        type:
                          type: string
                          enum:
                            - text
                            - textarea
                            - number
                            - date
                            - boolean
                            - select
                            - multi_select
                        value:
                          anyOf:
                            - type: object
                              properties:
                                text:
                                  description: Value for text/url/email/phone fields
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                number:
                                  description: Value for number fields
                                  anyOf:
                                    - anyOf:
                                        - type: number
                                        - type: string
                                    - type: 'null'
                                date:
                                  description: Value for date fields (ISO 8601 date string)
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                boolean:
                                  description: Value for checkbox fields
                                  anyOf:
                                    - anyOf:
                                        - type: boolean
                                        - type: string
                                    - type: 'null'
                                select:
                                  description: Option ID for single-select fields
                                  anyOf:
                                    - type: number
                                    - type: 'null'
                                multi_select:
                                  description: Option IDs for multi-select fields
                                  anyOf:
                                    - type: array
                                      items:
                                        type: number
                                    - type: 'null'
                              additionalProperties: false
                              description: >-
                                Custom field value. Set the key matching the
                                field type: text (text/url/email/phone), number,
                                date, boolean (checkbox), select (option ID), or
                                multi_select (array of option IDs).
                            - type: 'null'
                        options:
                          anyOf:
                            - type: array
                              items:
                                type: object
                                properties:
                                  id:
                                    type: number
                                  label:
                                    type: string
                                required:
                                  - id
                                  - label
                                additionalProperties: false
                            - type: 'null'
                        custom_field_value_id:
                          anyOf:
                            - type: string
                            - type: 'null'
                      required:
                        - id
                        - label
                        - type
                        - value
                        - options
                        - custom_field_value_id
                      additionalProperties: false
                  has_quote:
                    type: boolean
                  has_products:
                    type: boolean
                  has_live_calculators:
                    type: boolean
                  entry_commission_values:
                    type: array
                    items:
                      type: object
                      properties:
                        stage_label:
                          anyOf:
                            - type: string
                            - type: 'null'
                        commission_value:
                          type: integer
                          minimum: -9007199254740991
                          maximum: 9007199254740991
                      required:
                        - stage_label
                        - commission_value
                      additionalProperties: false
                  spiff_entry_commission_values:
                    type: array
                    items:
                      type: object
                      properties:
                        stage_label:
                          anyOf:
                            - type: string
                            - type: 'null'
                        commission_value:
                          type: integer
                          minimum: -9007199254740991
                          maximum: 9007199254740991
                        recipient_type:
                          anyOf:
                            - type: string
                              enum:
                                - partnership
                                - user
                                - contact
                            - type: 'null'
                        recipient_user_id:
                          type: string
                        recipient_contact_id:
                          type: string
                        recipient_name:
                          type: string
                      required:
                        - stage_label
                        - commission_value
                      additionalProperties: false
                  total_spiff_value:
                    type: integer
                    minimum: -9007199254740991
                    maximum: 9007199254740991
                  commission_overrides:
                    type: array
                    items:
                      type: object
                      properties:
                        stage_label:
                          anyOf:
                            - type: string
                            - type: 'null'
                        amount:
                          type: integer
                          minimum: 0
                          maximum: 9007199254740991
                        currency_code:
                          anyOf:
                            - type: string
                            - type: 'null'
                        note:
                          anyOf:
                            - type: string
                            - type: 'null'
                        document:
                          anyOf:
                            - type: object
                              properties:
                                uuid:
                                  type: string
                                file_url:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                file_name:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                mime_type:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                              required:
                                - uuid
                                - file_url
                                - file_name
                                - mime_type
                              additionalProperties: false
                            - type: 'null'
                      required:
                        - stage_label
                        - amount
                        - currency_code
                        - note
                        - document
                      additionalProperties: false
                  id:
                    type: string
                required:
                  - uuid
                  - created_at
                  - updated_at
                  - deal_value
                  - total_commission_occurrences
                  - lead_id
                  - total_commission_value
                  - stage_id
                  - label
                  - created_by_user_id
                  - expiration_date
                  - expired_at
                  - currency_code
                  - stage
                  - created_by_user_first_name
                  - created_by_user_last_name
                  - created_by_user_email
                  - created_by_user_profile_image_id
                  - created_by_user_profile_image_uuid
                  - lead_company_name
                  - lead_first_name
                  - lead_last_name
                  - lead_email
                  - lead_phone_number
                  - lead_direction
                  - lead_status
                  - lead_campaign_id
                  - campaign_title
                  - partnership
                  - tags
                  - assigned_users
                  - assigned_contacts
                  - custom_fields
                  - has_quote
                  - has_products
                  - has_live_calculators
                  - id
                additionalProperties: false
components:
  securitySchemes:
    apiKey:
      type: http
      scheme: bearer
      description: API key authentication. Use "Bearer <api_key>" or "Api-Key <api_key>".

````