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

# List Variation Orders

> Retrieve a paginated list of variation_orders. Use filters to narrow results.

## Filtering

Use the `filter[<attribute>]` parameter to filter results. Multiple filters are combined with AND logic.

### Basic Examples
```
# Equality (implicit)
GET /api/v4/variation_orders?filter[status]=draft

# Multiple values (implicit IN)
GET /api/v4/variation_orders?filter[status]=draft,accepted

# With explicit operator
GET /api/v4/variation_orders?filter[created_at][gte]=2024-01-01

# Range query
GET /api/v4/variation_orders?filter[original_rate][between]=1000000,5000000

# Multiple filters (AND)
GET /api/v4/variation_orders?filter[status]=draft&filter[original_rate][gte]=1000000
```

### Available Attributes

| Attribute | Type | Operators | Permitted Values |
|-----------|------|-----------|------------------|
| accepted_at | datetime | `eq`, `not_eq`, `gt`, `gte`, `lt`, `lte`, `between` | - |
| additional_terms | string | `eq`, `not_eq`, `in`, `not_in`, `like`, `not_like` | - |
| approved_at | datetime | `eq`, `not_eq`, `gt`, `gte`, `lt`, `lte`, `between` | - |
| approved_by_id | integer | `eq`, `not_eq`, `in`, `not_in`, `gt`, `gte`, `lt`, `lte`, `between` | - |
| approver_declined_reason | string | `eq`, `not_eq`, `in`, `not_in`, `like`, `not_like` | - |
| client_contract_template_id | integer | `eq`, `not_eq`, `in`, `not_in`, `gt`, `gte`, `lt`, `lte`, `between` | - |
| created_at | datetime | `eq`, `not_eq`, `gt`, `gte`, `lt`, `lte`, `between` | - |
| created_by_id | integer | `eq`, `not_eq`, `in`, `not_in`, `gt`, `gte`, `lt`, `lte`, `between` | - |
| current_approval_level | integer | `eq`, `not_eq`, `in`, `not_in`, `gt`, `gte`, `lt`, `lte`, `between` | - |
| declined_at | datetime | `eq`, `not_eq`, `gt`, `gte`, `lt`, `lte`, `between` | - |
| declined_reason | string | `eq`, `not_eq`, `in`, `not_in`, `like`, `not_like` | - |
| due_on | datetime | `eq`, `not_eq`, `gt`, `gte`, `lt`, `lte`, `between` | - |
| expires_at | datetime | `eq`, `not_eq`, `gt`, `gte`, `lt`, `lte`, `between` | - |
| id | integer | `eq`, `not_eq`, `in`, `not_in`, `gt`, `gte`, `lt`, `lte`, `between` | - |
| length_of_time | integer | `eq`, `not_eq`, `in`, `not_in`, `gt`, `gte`, `lt`, `lte`, `between` | - |
| original_rate | money | `eq`, `not_eq`, `in`, `not_in`, `gt`, `gte`, `lt`, `lte`, `between` | - |
| original_rate_ccy | string | `eq`, `not_eq`, `in`, `not_in`, `like`, `not_like` | - |
| project_id | integer | `eq`, `not_eq`, `in`, `not_in`, `gt`, `gte`, `lt`, `lte`, `between` | - |
| rate | money | `eq`, `not_eq`, `in`, `not_in`, `gt`, `gte`, `lt`, `lte`, `between` | - |
| rate_ccy | string | `eq`, `not_eq`, `in`, `not_in`, `like`, `not_like` | - |
| reject_reason | string | `eq`, `not_eq`, `in`, `not_in`, `like`, `not_like` | - |
| sent_at | datetime | `eq`, `not_eq`, `gt`, `gte`, `lt`, `lte`, `between` | - |
| skip_acceptance | boolean | `eq`, `not_eq` | - |
| start_date | date | `eq`, `not_eq`, `gt`, `gte`, `lt`, `lte`, `between` | - |
| status | string | `eq`, `not_eq`, `in`, `not_in` | `draft`, `pending`, `accepted`, `declined`, `withdrawn`, `expired`, `generating`, `signature_error`, `sending`, `rejected`, `cancelled`, `submitted`, `supplier_draft`, `supplier_proposed`, `supplier_rejected` |
| submitted_at | datetime | `eq`, `not_eq`, `gt`, `gte`, `lt`, `lte`, `between` | - |
| supplier_contract_template_id | integer | `eq`, `not_eq`, `in`, `not_in`, `gt`, `gte`, `lt`, `lte`, `between` | - |
| update_budget | boolean | `eq`, `not_eq` | - |
| updated_at | datetime | `eq`, `not_eq`, `gt`, `gte`, `lt`, `lte`, `between` | - |
| version_number | integer | `eq`, `not_eq`, `in`, `not_in`, `gt`, `gte`, `lt`, `lte`, `between` | - |

### Custom Fields

This resource supports custom field filtering using `cf[key]` syntax:
```
# Equality
GET /api/v4/variation_orders?cf[priority]=high

# With operator
GET /api/v4/variation_orders?cf[department][in]=engineering,design

# Check existence
GET /api/v4/variation_orders?cf[priority][exists]=

# Negation
GET /api/v4/variation_orders?cf[priority][not_eq]=low
```

### OR Conditions

Use `or[group]` to combine filter groups with OR logic. Filters within a group are ANDed:
```
# Simple OR
GET /api/v4/variation_orders?or[1][status]=pending&or[2][status]=draft

# Complex OR (status=pending AND original_rate>=1000000) OR (status=draft)
GET /api/v4/variation_orders?or[1][status]=pending&or[1][original_rate][gte]=1000000&or[2][status]=draft
```

## Sorting

Use `sort[<attribute>]` to order results. Default direction is ascending.
```
# Ascending (implicit)
GET /api/v4/variation_orders?sort[created_at]=

# Descending
GET /api/v4/variation_orders?sort[created_at]=desc

# Combined with filters
GET /api/v4/variation_orders?filter[status]=draft&sort[created_at]=desc
```



## OpenAPI

````yaml /api-reference/v4/openapi.json get /variation_orders
openapi: 3.1.0
info:
  title: API V4
  version: '4'
  description: >-
    OAuth 2.0 secured API. Obtain an access token using client credentials to
    access protected endpoints. The regional endpoints listed below serve every
    Zivio organisation, so each request — including the token request — must
    carry a `zivio-tenant-id` header identifying yours. Requests without it are
    rejected with a 404 before any token is checked.
  contact:
    name: API Support
    email: support@zivio.com
servers:
  - url: https://api.zivio.net/api/v4
    description: Global API Router
  - url: https://api.eu.zivio.net/api/v4
    description: EU Data Region
  - url: https://api.uk.zivio.net/api/v4
    description: UK Data Region
  - url: https://api.us.zivio.net/api/v4
    description: US Data Region
security:
  - oauth2: []
    tenantId: []
paths:
  /variation_orders:
    get:
      tags:
        - Variation Orders
      summary: List Variation Orders
      description: >-
        Retrieve a paginated list of variation_orders. Use filters to narrow
        results.


        ## Filtering


        Use the `filter[<attribute>]` parameter to filter results. Multiple
        filters are combined with AND logic.


        ### Basic Examples

        ```

        # Equality (implicit)

        GET /api/v4/variation_orders?filter[status]=draft


        # Multiple values (implicit IN)

        GET /api/v4/variation_orders?filter[status]=draft,accepted


        # With explicit operator

        GET /api/v4/variation_orders?filter[created_at][gte]=2024-01-01


        # Range query

        GET
        /api/v4/variation_orders?filter[original_rate][between]=1000000,5000000


        # Multiple filters (AND)

        GET
        /api/v4/variation_orders?filter[status]=draft&filter[original_rate][gte]=1000000

        ```


        ### Available Attributes


        | Attribute | Type | Operators | Permitted Values |

        |-----------|------|-----------|------------------|

        | accepted_at | datetime | `eq`, `not_eq`, `gt`, `gte`, `lt`, `lte`,
        `between` | - |

        | additional_terms | string | `eq`, `not_eq`, `in`, `not_in`, `like`,
        `not_like` | - |

        | approved_at | datetime | `eq`, `not_eq`, `gt`, `gte`, `lt`, `lte`,
        `between` | - |

        | approved_by_id | integer | `eq`, `not_eq`, `in`, `not_in`, `gt`,
        `gte`, `lt`, `lte`, `between` | - |

        | approver_declined_reason | string | `eq`, `not_eq`, `in`, `not_in`,
        `like`, `not_like` | - |

        | client_contract_template_id | integer | `eq`, `not_eq`, `in`,
        `not_in`, `gt`, `gte`, `lt`, `lte`, `between` | - |

        | created_at | datetime | `eq`, `not_eq`, `gt`, `gte`, `lt`, `lte`,
        `between` | - |

        | created_by_id | integer | `eq`, `not_eq`, `in`, `not_in`, `gt`, `gte`,
        `lt`, `lte`, `between` | - |

        | current_approval_level | integer | `eq`, `not_eq`, `in`, `not_in`,
        `gt`, `gte`, `lt`, `lte`, `between` | - |

        | declined_at | datetime | `eq`, `not_eq`, `gt`, `gte`, `lt`, `lte`,
        `between` | - |

        | declined_reason | string | `eq`, `not_eq`, `in`, `not_in`, `like`,
        `not_like` | - |

        | due_on | datetime | `eq`, `not_eq`, `gt`, `gte`, `lt`, `lte`,
        `between` | - |

        | expires_at | datetime | `eq`, `not_eq`, `gt`, `gte`, `lt`, `lte`,
        `between` | - |

        | id | integer | `eq`, `not_eq`, `in`, `not_in`, `gt`, `gte`, `lt`,
        `lte`, `between` | - |

        | length_of_time | integer | `eq`, `not_eq`, `in`, `not_in`, `gt`,
        `gte`, `lt`, `lte`, `between` | - |

        | original_rate | money | `eq`, `not_eq`, `in`, `not_in`, `gt`, `gte`,
        `lt`, `lte`, `between` | - |

        | original_rate_ccy | string | `eq`, `not_eq`, `in`, `not_in`, `like`,
        `not_like` | - |

        | project_id | integer | `eq`, `not_eq`, `in`, `not_in`, `gt`, `gte`,
        `lt`, `lte`, `between` | - |

        | rate | money | `eq`, `not_eq`, `in`, `not_in`, `gt`, `gte`, `lt`,
        `lte`, `between` | - |

        | rate_ccy | string | `eq`, `not_eq`, `in`, `not_in`, `like`, `not_like`
        | - |

        | reject_reason | string | `eq`, `not_eq`, `in`, `not_in`, `like`,
        `not_like` | - |

        | sent_at | datetime | `eq`, `not_eq`, `gt`, `gte`, `lt`, `lte`,
        `between` | - |

        | skip_acceptance | boolean | `eq`, `not_eq` | - |

        | start_date | date | `eq`, `not_eq`, `gt`, `gte`, `lt`, `lte`,
        `between` | - |

        | status | string | `eq`, `not_eq`, `in`, `not_in` | `draft`, `pending`,
        `accepted`, `declined`, `withdrawn`, `expired`, `generating`,
        `signature_error`, `sending`, `rejected`, `cancelled`, `submitted`,
        `supplier_draft`, `supplier_proposed`, `supplier_rejected` |

        | submitted_at | datetime | `eq`, `not_eq`, `gt`, `gte`, `lt`, `lte`,
        `between` | - |

        | supplier_contract_template_id | integer | `eq`, `not_eq`, `in`,
        `not_in`, `gt`, `gte`, `lt`, `lte`, `between` | - |

        | update_budget | boolean | `eq`, `not_eq` | - |

        | updated_at | datetime | `eq`, `not_eq`, `gt`, `gte`, `lt`, `lte`,
        `between` | - |

        | version_number | integer | `eq`, `not_eq`, `in`, `not_in`, `gt`,
        `gte`, `lt`, `lte`, `between` | - |


        ### Custom Fields


        This resource supports custom field filtering using `cf[key]` syntax:

        ```

        # Equality

        GET /api/v4/variation_orders?cf[priority]=high


        # With operator

        GET /api/v4/variation_orders?cf[department][in]=engineering,design


        # Check existence

        GET /api/v4/variation_orders?cf[priority][exists]=


        # Negation

        GET /api/v4/variation_orders?cf[priority][not_eq]=low

        ```


        ### OR Conditions


        Use `or[group]` to combine filter groups with OR logic. Filters within a
        group are ANDed:

        ```

        # Simple OR

        GET /api/v4/variation_orders?or[1][status]=pending&or[2][status]=draft


        # Complex OR (status=pending AND original_rate>=1000000) OR
        (status=draft)

        GET
        /api/v4/variation_orders?or[1][status]=pending&or[1][original_rate][gte]=1000000&or[2][status]=draft

        ```


        ## Sorting


        Use `sort[<attribute>]` to order results. Default direction is
        ascending.

        ```

        # Ascending (implicit)

        GET /api/v4/variation_orders?sort[created_at]=


        # Descending

        GET /api/v4/variation_orders?sort[created_at]=desc


        # Combined with filters

        GET /api/v4/variation_orders?filter[status]=draft&sort[created_at]=desc

        ```
      operationId: getVariationOrders
      parameters:
        - name: page
          in: query
          schema:
            type: integer
            default: 1
          description: Page number for pagination
        - name: limit
          in: query
          schema:
            type: integer
            default: 20
            maximum: 100
          description: Number of results per page (max 100)
        - name: filter[<attribute>]
          in: query
          style: deepObject
          explode: true
          schema:
            type: object
          description: >-
            Filterable attributes:


            **integer** (operators: eq, not_eq, in, not_in, gt, gte, lt, lte,
            between): approved_by_id, client_contract_template_id,
            created_by_id, current_approval_level, id, length_of_time,
            project_id, supplier_contract_template_id, version_number

            **datetime** (operators: eq, not_eq, gt, gte, lt, lte, between):
            accepted_at, approved_at, created_at, declined_at, due_on,
            expires_at, sent_at, submitted_at, updated_at

            **string** (operators: eq, not_eq, in, not_in, like, not_like):
            additional_terms, approver_declined_reason, declined_reason,
            original_rate_ccy, rate_ccy, reject_reason, status (one of: draft,
            pending, accepted, declined, withdrawn, expired, generating,
            signature_error, sending, rejected, cancelled, submitted,
            supplier_draft, supplier_proposed, supplier_rejected)

            **money** (operators: eq, not_eq, in, not_in, gt, gte, lt, lte,
            between): original_rate, rate

            **boolean** (operators: eq, not_eq): skip_acceptance, update_budget

            **date** (operators: eq, not_eq, gt, gte, lt, lte, between):
            start_date


            Note: money values are in minor currency units (e.g. pence for GBP).
            Use 1000000 for £10,000.00.


            Note: `like` is a case-insensitive substring match — pass the bare
            term (filter[title][like]=redesign). Do not add % wildcards; they
            are not needed.
          examples:
            equality:
              summary: Simple equality
              value:
                status: draft
            multiple_values:
              summary: Multiple values (implicit IN)
              value:
                status: draft,accepted
            with_operator:
              summary: With explicit operator
              value:
                created_at:
                  gte: '2024-01-01'
            range:
              summary: Range query
              value:
                original_rate:
                  between: 1000000,5000000
        - name: or[group]
          in: query
          style: deepObject
          explode: true
          schema:
            type: object
          description: >-
            OR condition groups. Filters within a group are ANDed; groups are
            ORed.


            **Syntax**: `or[group_key][<attribute>]=value` or
            `or[group_key][<attribute>][operator]=value`


            **Examples**:

            - Simple OR: `or[1][state]=draft&or[2][state]=pending`

            - Complex:
            `or[1][state]=draft&or[1][budget][gte]=50000&or[2][state]=closed`

            - With custom fields:
            `or[1][cf][priority]=high&or[2][state]=pending`


            Group keys can be any string (1, 2, a, b, etc.) - they just need to
            be unique.
          examples:
            simple_or:
              summary: Simple OR
              value:
                '1':
                  status: pending
                '2':
                  status: draft
            complex_or:
              summary: Complex OR with AND within groups
              value:
                '1':
                  status: pending
                  original_rate:
                    gte: '1000000'
                '2':
                  status: draft
        - name: cf[key]
          in: query
          style: deepObject
          explode: true
          schema:
            type: object
          description: >-
            Custom field filters using concise syntax.


            **Syntax**:

            - Equality: `cf[key]=value`

            - With operator: `cf[key][operator]=value`


            **Operators**: eq (default), not_eq, in, not_in, contains,
            not_contains, exists, not_exists


            **Examples**:

            - `cf[priority]=high` - exact match

            - `cf[department][in]=eng,design` - matches any

            - `cf[priority][not_eq]=low` - not equal

            - `cf[notes][contains]=urgent` - contains text

            - `cf[legacy_field][exists]=` - field exists (value ignored)

            - `cf[deprecated][not_exists]=` - field does not exist
          examples:
            equality:
              summary: Simple equality
              value:
                priority: high
            with_operator:
              summary: With IN operator
              value:
                department:
                  in: eng,design
            exists:
              summary: Check existence
              value:
                priority:
                  exists: ''
        - name: or[group][cf][key]
          in: query
          style: deepObject
          explode: true
          schema:
            type: object
          description: >-
            Custom field filters within OR condition groups.


            **Syntax**: `or[group][cf][key]=value` or
            `or[group][cf][key][operator]=value`


            **Example**: `or[1][cf][priority]=high&or[2][state]=pending`
        - name: sort[<attribute>]
          in: query
          style: deepObject
          explode: true
          schema:
            type: object
          description: >-
            Sort results by attribute. Direction defaults to ascending.


            **Syntax**: `sort[<attribute>]=` (ascending) or
            `sort[<attribute>]=desc` (descending)


            **Sortable attributes**: accepted_at, additional_terms, approved_at,
            approved_by_id, approver_declined_reason,
            client_contract_template_id, created_at, created_by_id,
            current_approval_level, declined_at, declined_reason, due_on,
            expires_at, id, length_of_time, original_rate, original_rate_ccy,
            project_id, rate, rate_ccy, reject_reason, sent_at, skip_acceptance,
            start_date, status, submitted_at, supplier_contract_template_id,
            update_budget, updated_at, version_number


            **Examples**:

            - Ascending: `sort[created_at]=` or `sort[created_at]=asc`

            - Descending: `sort[created_at]=desc`
          examples:
            ascending:
              summary: Ascending (implicit)
              value:
                created_at: ''
            descending:
              summary: Descending
              value:
                created_at: desc
      responses:
        '200':
          description: List of variation_orders
          content:
            application/json:
              schema:
                type: object
                properties:
                  variation_orders:
                    type: array
                    items:
                      $ref: '#/components/schemas/VariationOrder'
              examples:
                success:
                  summary: Successful response with variation_orders
                  value:
                    variation_orders:
                      - id: 101
                        version_number: 101
                        status: pending
                        rate:
                          cents: 150000
                          currency: GBP
                        original_rate:
                          cents: 150000
                          currency: GBP
                        additional_terms: Example additional_terms
                        created_by:
                          id: 101
                          first_name: Demo
                          last_name: User
                          email: user1@example.com
                          org_id: 501
                          org_name: Acme Corporation
                        supplier_contract_template: null
                        client_contract_template: null
                        skip_acceptance: true
                        submitted_at: '2024-01-16T10:30:00+00:00'
                        sent_at: '2024-01-16T10:30:00+00:00'
                        start_date: '2024-03-08'
                        due_on: '2024-01-16'
                        expires_at: '2024-01-16T10:30:00+00:00'
                        accepted_at: '2024-01-16T10:30:00+00:00'
                        approved_at: '2024-01-16T10:30:00+00:00'
                        approved_by:
                          id: 101
                          first_name: Demo
                          last_name: User
                          email: user1@example.com
                          org_id: 501
                          org_name: Acme Corporation
                        approver_declined_reason: Example approver_declined_reason
                        declined_at: '2024-01-16T10:30:00+00:00'
                        declined_reason: Example declined_reason
                        reject_reason: Example reject_reason
                        milestone_variations:
                          - id: 101
                            variation_order_id: 501
                            original_title: Phase 1 Milestone
                            varied_title: Phase 1 Milestone
                            original_details: Milestone details and requirements
                            varied_details: Milestone details and requirements
                            original_due_on: '2024-01-16'
                            varied_due_on: '2024-01-16'
                            original_rate:
                              cents: 150000
                              currency: GBP
                            varied_rate:
                              cents: 150000
                              currency: GBP
                            original_tiered_markup_fee:
                              cents: 150000
                              currency: GBP
                            varied_tiered_markup_fee:
                              cents: 150000
                              currency: GBP
                            client_suggested: false
                            milestone_id: 501
                            custom_fields:
                              department: Engineering
                              priority: high
                              cost_code: CC-001
                          - id: 102
                            variation_order_id: 502
                            original_title: Phase 2 Milestone
                            varied_title: Phase 2 Milestone
                            original_details: Milestone details and requirements
                            varied_details: Milestone details and requirements
                            original_due_on: '2024-01-17'
                            varied_due_on: '2024-01-17'
                            original_rate:
                              cents: 300000
                              currency: GBP
                            varied_rate:
                              cents: 300000
                              currency: GBP
                            original_tiered_markup_fee:
                              cents: 300000
                              currency: GBP
                            varied_tiered_markup_fee:
                              cents: 300000
                              currency: GBP
                            client_suggested: false
                            milestone_id: 502
                            custom_fields:
                              department: Engineering
                              priority: high
                              cost_code: CC-001
                        custom_fields:
                          department: Engineering
                          priority: high
                          cost_code: CC-001
                        created_at: '2024-01-16T10:30:00+00:00'
                        updated_at: '2024-01-16T10:30:00+00:00'
                        project:
                          id: 101
                          title: Website Redesign Project
                          description: >-
                            Complete redesign of corporate website with modern
                            UX
                        project_line_item_variations:
                          - id: 101
                            variation_order_id: 501
                            original_name: Line Item Name
                            varied_name: Line Item Name
                            original_manufacturer_name: ACME Manufacturing
                            varied_manufacturer_name: ACME Manufacturing
                            original_manufacturer_part_number: PART-1001
                            varied_manufacturer_part_number: PART-1001
                            original_quantity: '10.0'
                            varied_quantity: '10.0'
                            original_price:
                              cents: 150000
                              currency: GBP
                            varied_price:
                              cents: 150000
                              currency: GBP
                            original_uom: null
                            varied_uom: null
                            item_id: 501
                            project_line_item_id: 501
                          - id: 102
                            variation_order_id: 502
                            original_name: Line Item Name
                            varied_name: Line Item Name
                            original_manufacturer_name: ACME Manufacturing
                            varied_manufacturer_name: ACME Manufacturing
                            original_manufacturer_part_number: PART-1002
                            varied_manufacturer_part_number: PART-1002
                            original_quantity: '10.0'
                            varied_quantity: '10.0'
                            original_price:
                              cents: 300000
                              currency: GBP
                            varied_price:
                              cents: 300000
                              currency: GBP
                            original_uom: null
                            varied_uom: null
                            item_id: 502
                            project_line_item_id: 502
                      - id: 102
                        version_number: 102
                        status: accepted
                        rate:
                          cents: 300000
                          currency: GBP
                        original_rate:
                          cents: 300000
                          currency: GBP
                        additional_terms: Example additional_terms
                        created_by:
                          id: 102
                          first_name: Jane
                          last_name: Smith
                          email: user2@example.com
                          org_id: 502
                          org_name: Global Services Ltd
                        supplier_contract_template: null
                        client_contract_template: null
                        skip_acceptance: true
                        submitted_at: '2024-01-17T10:30:00+00:00'
                        sent_at: '2024-01-17T10:30:00+00:00'
                        start_date: '2024-03-15'
                        due_on: '2024-01-17'
                        expires_at: '2024-01-17T10:30:00+00:00'
                        accepted_at: '2024-01-17T10:30:00+00:00'
                        approved_at: '2024-01-17T10:30:00+00:00'
                        approved_by:
                          id: 102
                          first_name: Jane
                          last_name: Smith
                          email: user2@example.com
                          org_id: 502
                          org_name: Global Services Ltd
                        approver_declined_reason: Example approver_declined_reason
                        declined_at: '2024-01-17T10:30:00+00:00'
                        declined_reason: Example declined_reason
                        reject_reason: Example reject_reason
                        milestone_variations:
                          - id: 102
                            variation_order_id: 502
                            original_title: Phase 2 Milestone
                            varied_title: Phase 2 Milestone
                            original_details: Milestone details and requirements
                            varied_details: Milestone details and requirements
                            original_due_on: '2024-01-17'
                            varied_due_on: '2024-01-17'
                            original_rate:
                              cents: 300000
                              currency: GBP
                            varied_rate:
                              cents: 300000
                              currency: GBP
                            original_tiered_markup_fee:
                              cents: 300000
                              currency: GBP
                            varied_tiered_markup_fee:
                              cents: 300000
                              currency: GBP
                            client_suggested: false
                            milestone_id: 502
                            custom_fields:
                              department: Engineering
                              priority: high
                              cost_code: CC-001
                          - id: 103
                            variation_order_id: 503
                            original_title: Phase 2 Milestone
                            varied_title: Phase 2 Milestone
                            original_details: Milestone details and requirements
                            varied_details: Milestone details and requirements
                            original_due_on: '2024-01-18'
                            varied_due_on: '2024-01-18'
                            original_rate:
                              cents: 450000
                              currency: GBP
                            varied_rate:
                              cents: 450000
                              currency: GBP
                            original_tiered_markup_fee:
                              cents: 450000
                              currency: GBP
                            varied_tiered_markup_fee:
                              cents: 450000
                              currency: GBP
                            client_suggested: false
                            milestone_id: 503
                            custom_fields:
                              department: Engineering
                              priority: high
                              cost_code: CC-001
                        custom_fields:
                          department: Engineering
                          priority: high
                          cost_code: CC-001
                        created_at: '2024-01-17T10:30:00+00:00'
                        updated_at: '2024-01-17T10:30:00+00:00'
                        project:
                          id: 102
                          title: Mobile App Development
                          description: Native iOS and Android application
                        project_line_item_variations:
                          - id: 102
                            variation_order_id: 502
                            original_name: Line Item Name
                            varied_name: Line Item Name
                            original_manufacturer_name: ACME Manufacturing
                            varied_manufacturer_name: ACME Manufacturing
                            original_manufacturer_part_number: PART-1002
                            varied_manufacturer_part_number: PART-1002
                            original_quantity: '10.0'
                            varied_quantity: '10.0'
                            original_price:
                              cents: 300000
                              currency: GBP
                            varied_price:
                              cents: 300000
                              currency: GBP
                            original_uom: null
                            varied_uom: null
                            item_id: 502
                            project_line_item_id: 502
                          - id: 103
                            variation_order_id: 503
                            original_name: Line Item Name
                            varied_name: Line Item Name
                            original_manufacturer_name: ACME Manufacturing
                            varied_manufacturer_name: ACME Manufacturing
                            original_manufacturer_part_number: PART-1003
                            varied_manufacturer_part_number: PART-1003
                            original_quantity: '10.0'
                            varied_quantity: '10.0'
                            original_price:
                              cents: 450000
                              currency: GBP
                            varied_price:
                              cents: 450000
                              currency: GBP
                            original_uom: null
                            varied_uom: null
                            item_id: 503
                            project_line_item_id: 503
                empty:
                  summary: Empty result set
                  value:
                    variation_orders: []
                filtered:
                  summary: Filtered results
                  description: Results after applying filters
                  value:
                    variation_orders:
                      - id: 101
                        version_number: 101
                        status: pending
                        rate:
                          cents: 150000
                          currency: GBP
                        original_rate:
                          cents: 150000
                          currency: GBP
                        additional_terms: Example additional_terms
                        created_by:
                          id: 101
                          first_name: Demo
                          last_name: User
                          email: user1@example.com
                          org_id: 501
                          org_name: Acme Corporation
                        supplier_contract_template: null
                        client_contract_template: null
                        skip_acceptance: true
                        submitted_at: '2024-01-16T10:30:00+00:00'
                        sent_at: '2024-01-16T10:30:00+00:00'
                        start_date: '2024-03-08'
                        due_on: '2024-01-16'
                        expires_at: '2024-01-16T10:30:00+00:00'
                        accepted_at: '2024-01-16T10:30:00+00:00'
                        approved_at: '2024-01-16T10:30:00+00:00'
                        approved_by:
                          id: 101
                          first_name: Demo
                          last_name: User
                          email: user1@example.com
                          org_id: 501
                          org_name: Acme Corporation
                        approver_declined_reason: Example approver_declined_reason
                        declined_at: '2024-01-16T10:30:00+00:00'
                        declined_reason: Example declined_reason
                        reject_reason: Example reject_reason
                        milestone_variations:
                          - id: 101
                            variation_order_id: 501
                            original_title: Phase 1 Milestone
                            varied_title: Phase 1 Milestone
                            original_details: Milestone details and requirements
                            varied_details: Milestone details and requirements
                            original_due_on: '2024-01-16'
                            varied_due_on: '2024-01-16'
                            original_rate:
                              cents: 150000
                              currency: GBP
                            varied_rate:
                              cents: 150000
                              currency: GBP
                            original_tiered_markup_fee:
                              cents: 150000
                              currency: GBP
                            varied_tiered_markup_fee:
                              cents: 150000
                              currency: GBP
                            client_suggested: false
                            milestone_id: 501
                            custom_fields:
                              department: Engineering
                              priority: high
                              cost_code: CC-001
                          - id: 102
                            variation_order_id: 502
                            original_title: Phase 2 Milestone
                            varied_title: Phase 2 Milestone
                            original_details: Milestone details and requirements
                            varied_details: Milestone details and requirements
                            original_due_on: '2024-01-17'
                            varied_due_on: '2024-01-17'
                            original_rate:
                              cents: 300000
                              currency: GBP
                            varied_rate:
                              cents: 300000
                              currency: GBP
                            original_tiered_markup_fee:
                              cents: 300000
                              currency: GBP
                            varied_tiered_markup_fee:
                              cents: 300000
                              currency: GBP
                            client_suggested: false
                            milestone_id: 502
                            custom_fields:
                              department: Engineering
                              priority: high
                              cost_code: CC-001
                        custom_fields:
                          department: Engineering
                          priority: high
                          cost_code: CC-001
                        created_at: '2024-01-16T10:30:00+00:00'
                        updated_at: '2024-01-16T10:30:00+00:00'
                        project:
                          id: 101
                          title: Website Redesign Project
                          description: >-
                            Complete redesign of corporate website with modern
                            UX
                        project_line_item_variations:
                          - id: 101
                            variation_order_id: 501
                            original_name: Line Item Name
                            varied_name: Line Item Name
                            original_manufacturer_name: ACME Manufacturing
                            varied_manufacturer_name: ACME Manufacturing
                            original_manufacturer_part_number: PART-1001
                            varied_manufacturer_part_number: PART-1001
                            original_quantity: '10.0'
                            varied_quantity: '10.0'
                            original_price:
                              cents: 150000
                              currency: GBP
                            varied_price:
                              cents: 150000
                              currency: GBP
                            original_uom: null
                            varied_uom: null
                            item_id: 501
                            project_line_item_id: 501
                          - id: 102
                            variation_order_id: 502
                            original_name: Line Item Name
                            varied_name: Line Item Name
                            original_manufacturer_name: ACME Manufacturing
                            varied_manufacturer_name: ACME Manufacturing
                            original_manufacturer_part_number: PART-1002
                            varied_manufacturer_part_number: PART-1002
                            original_quantity: '10.0'
                            varied_quantity: '10.0'
                            original_price:
                              cents: 300000
                              currency: GBP
                            varied_price:
                              cents: 300000
                              currency: GBP
                            original_uom: null
                            varied_uom: null
                            item_id: 502
                            project_line_item_id: 502
        '401':
          description: >-
            Unauthorized - the access token is missing, expired, revoked or
            malformed
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                error: invalid_token
                error_description: >-
                  The access token provided is expired, revoked, malformed, or
                  invalid for other reasons
        '403':
          description: Forbidden - insufficient scope
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                error: insufficient_scope
                error_description: >-
                  The request requires higher privileges than provided by the
                  access token
                required_scope: variation_orders:read
                provided_scopes:
                  - welcome:read
        '422':
          description: Invalid filter or sort parameters
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              examples:
                invalid_attribute:
                  summary: Unknown filter attribute
                  value:
                    error: 'Invalid filter attribute: unknown_field'
                invalid_operator:
                  summary: Invalid operator for type
                  value:
                    error: Operator 'like' is not valid for integer type
                invalid_value:
                  summary: Invalid value format
                  value:
                    error: 'Invalid date format for created_at: not-a-date'
                invalid_sort_attribute:
                  summary: Unknown sort attribute
                  value:
                    error: 'Invalid sort attribute: unknown_field'
                invalid_sort_direction:
                  summary: Invalid sort direction
                  value:
                    error: Invalid sort direction 'random'. Must be 'asc' or 'desc'
      security:
        - oauth2:
            - variation_orders:read
          tenantId: []
components:
  schemas:
    VariationOrder:
      type: object
      properties:
        id:
          type: integer
        version_number:
          type: integer
        status:
          type: string
          enum:
            - draft
            - pending
            - accepted
            - declined
            - withdrawn
            - expired
            - generating
            - signature_error
            - sending
            - rejected
            - cancelled
            - submitted
            - supplier_draft
            - supplier_proposed
            - supplier_rejected
          example: draft
        rate:
          $ref: '#/components/schemas/Money'
        original_rate:
          $ref: '#/components/schemas/Money'
        additional_terms:
          type: string
        created_by:
          oneOf:
            - $ref: '#/components/schemas/EmbeddedUser'
            - type: 'null'
        supplier_contract_template:
          type: string
        client_contract_template:
          type: string
        skip_acceptance:
          type: boolean
          example: true
        submitted_at:
          type: string
        sent_at:
          type: string
        start_date:
          type: string
        due_on:
          type: string
        expires_at:
          type: string
        accepted_at:
          type: string
        approved_at:
          type: string
        approved_by:
          oneOf:
            - $ref: '#/components/schemas/EmbeddedUser'
            - type: 'null'
        approver_declined_reason:
          type: string
        declined_at:
          type: string
        declined_reason:
          type: string
        reject_reason:
          type: string
        milestone_variations:
          type: array
          items:
            $ref: '#/components/schemas/EmbeddedMilestoneVariation'
        custom_fields:
          type: object
          additionalProperties:
            type: string
          description: Key-value pairs of custom field data
        created_at:
          type: string
        updated_at:
          type: string
        project:
          oneOf:
            - $ref: '#/components/schemas/EmbeddedProject'
            - type: 'null'
        project_line_item_variations:
          type: array
          items:
            $ref: '#/components/schemas/EmbeddedProjectLineItemVariation'
    Error:
      type: object
      description: Error envelope returned by every non-2xx V4 response
      properties:
        error:
          type: string
          example: insufficient_scope
        error_description:
          type: string
        message:
          type: string
        details:
          type: object
          additionalProperties: true
        required_scope:
          type: string
          example: projects:read
        provided_scopes:
          type: array
          items:
            type: string
    Money:
      type: object
      properties:
        cents:
          type: integer
          example: 150000
        currency:
          type: string
          example: GBP
    EmbeddedUser:
      type: object
      properties:
        id:
          type: integer
        first_name:
          type: string
        last_name:
          type: string
        email:
          type: string
        org_id:
          type: integer
        org_name:
          type: string
    EmbeddedMilestoneVariation:
      type: object
      properties:
        id:
          type: integer
        variation_order_id:
          type: integer
        original_title:
          type: string
        varied_title:
          type: string
        original_details:
          type: string
        varied_details:
          type: string
        original_due_on:
          type: string
        varied_due_on:
          type: string
        original_rate:
          $ref: '#/components/schemas/Money'
        varied_rate:
          $ref: '#/components/schemas/Money'
        original_tiered_markup_fee:
          $ref: '#/components/schemas/Money'
        varied_tiered_markup_fee:
          $ref: '#/components/schemas/Money'
        client_suggested:
          type: boolean
          example: true
        milestone_id:
          type: integer
        custom_fields:
          type: object
          additionalProperties:
            type: string
          description: Key-value pairs of custom field data
    EmbeddedProject:
      type: object
      properties:
        id:
          type: integer
        title:
          type: string
        description:
          type: string
    EmbeddedProjectLineItemVariation:
      type: object
      properties:
        id:
          type: integer
        variation_order_id:
          type: integer
        original_name:
          type: string
        varied_name:
          type: string
        original_manufacturer_name:
          type: string
        varied_manufacturer_name:
          type: string
        original_manufacturer_part_number:
          type: string
        varied_manufacturer_part_number:
          type: string
        original_quantity:
          type: string
        varied_quantity:
          type: string
        original_price:
          $ref: '#/components/schemas/Money'
        varied_price:
          $ref: '#/components/schemas/Money'
        original_uom:
          type: string
        varied_uom:
          type: string
        item_id:
          type: integer
        project_line_item_id:
          type: integer
  securitySchemes:
    oauth2:
      type: oauth2
      description: >-
        OAuth 2.0 client credentials. The access token from POST /oauth/token is
        sent as a bearer token. Request only the scopes you need.
      flows:
        clientCredentials:
          tokenUrl: https://api.zivio.net/api/v4/oauth/token
          scopes:
            bank_accounts:read: Read bank account details on suppliers and the org.
            catalogs:read: Read catalog items.
            cost_centers:read: Read cost center records.
            eoi_responses:read: Read responses to expressions of interest.
            eois:read: Read expressions of interest.
            offers:read: Read offers for projects.
            org_units:read: Read your organization unit hierarchy.
            org_users:read: Read members of your organization.
            resources:read: Read resource (worker) records.
            sales_invoices:read: Read invoices issued to clients.
            sales_milestones:read: Read milestones on sales engagements.
            skill_categories:read: Read the skill category taxonomy.
            skill_taxonomies:read: Read skill taxonomy structure.
            skills:read: Read individual skills.
            supplier_documents:read: Read documents uploaded by suppliers.
            supplier_lists:read: Read curated lists of suppliers.
            supplier_users:read: Read users belonging to supplier organizations.
            tax_types:read: Read configured tax types.
            users:read: Read user profiles.
            variation_orders:read: Read variation orders on projects.
            welcome:read: 'Required: confirms your identity to the application.'
            bid_evaluations:read: >-
              Read evaluation scorecards for bids, including criterion scores
              and quality, cost and total scores.
            bid_evaluations:write: >-
              Score bids against a project's quality criteria and override
              calculated cost scores.
            bids:read: Read bids submitted on projects.
            bids:write: >-
              Shortlist, select, eliminate and reinstate bids submitted on
              projects.
            invoices:read: Read invoices on projects.
            invoices:write: Create and update invoices.
            notes:read: Read notes on projects and EOIs.
            notes:write: Create and update notes on projects and EOIs.
            project_approvals:read: Read project approval workflows.
            project_approvals:write: Create and update project approval workflows.
            project_conversations:read: Read messages exchanged with suppliers on a project.
            project_conversations:write: Send messages to suppliers on a project.
            project_invitations:read: Read supplier invitations on projects.
            project_invitations:write: Invite suppliers to bid on projects.
            project_questions:read: Read supplier clarification questions on projects.
            project_questions:write: Answer and approve supplier clarification questions.
            projects:read: Read projects.
            projects:write: Create and update projects.
            milestones:read: Read milestones on projects.
            milestones:write: Create and update milestones.
            orgs:read: Read organization records.
            orgs:write: Create and update organization records.
            purchase_orders:read: Read purchase orders.
            purchase_orders:write: Create and update purchase orders.
            reviews:read: Read reviews left on suppliers.
            reviews:write: Create and update reviews.
            suppliers:read: Read supplier profiles.
            suppliers:write: Create and update supplier profiles.
            raw_scorecard_entries:write: Create and update raw scorecard entries.
            raw_scorecard_entries:read: Read raw scorecard entries.
            tasks:read: >-
              Read the acting user's task queue, including outstanding approvals
              and items to review.
            tasks:write: Complete and dismiss tasks in the acting user's task queue.
            act_as_user: >-
              Make requests as another user within the token holder's delegation
              boundary.
    tenantId:
      type: apiKey
      name: zivio-tenant-id
      in: header
      description: >-
        Your Zivio organisation identifier. The regional API endpoints serve
        every Zivio organisation, so each request must identify yours.

````