{
  "openapi": "3.0.1",
  "info": {
    "title": "TenderHub Data API",
    "description": "Read-only access to TenderHub awarded contracts, opportunities, supplier and buyer records for organisations on the paid Enterprise plan. Authenticate every request with an organisation API key in the X-Api-Key header. Opportunities, suppliers and buyers are identified by opaque, stable ids (TH-, SUP-, BUY-): store those, not names or slugs, which can change. Statuses, types and states are lowercase codes; categories and locations are the slugs the TenderHub website uses. Errors are application/problem+json with a stable code. Rate limits and the daily quota are reported in the RateLimit-* and X-Daily-Quota-* response headers.",
    "version": "v1"
  },
  "servers": [
    {
      "url": "https://api.tenderhub.com.au"
    }
  ],
  "paths": {
    "/api/integration/v1/awards": {
      "get": {
        "tags": [
          "Awards"
        ],
        "summary": "Lists opportunities whose awards changed since a point in time, oldest change first.",
        "description": "One item per awarded opportunity. Each item carries the complete current set of awards for that opportunity, so\nreplace what you stored for it. Start with since, then follow nextCursor while hasMore is true. Pages may be short\nor empty while hasMore is true. Keep the last nextCursor and poll with it later to receive only newer changes.\nHistory is limited to 24 months: a change recorded earlier is never returned, even through an older cursor. A cursor\nis never refused for its age. If your last poll (or your cursor) is more than 24 months old, changes in the gap,\nincluding supplier hidden and deleted entries, cannot be delivered. To keep your copy accurate, we recommend that\nyou first re-verify every supplier you hold with GET /suppliers/{supplierId} (a 404 means it is no longer\npublished; that call needs suppliers:read), then resume from the earliest allowed since.\n\nRequires scope: awards:read.",
        "operationId": "AwardsList",
        "parameters": [
          {
            "name": "since",
            "in": "query",
            "description": "Only changes recorded at or after this instant (ISO-8601 UTC, for example 2026-01-01T00:00:00Z). Required when no cursor is given. At most 24 months back: an older since is refused with 400 since_too_old, whose detail gives the earliest allowed value (midnight UTC on the same date 24 months ago).",
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "description": "The nextCursor value from the previous page, exactly as returned.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "description": "Maximum items per page, 1 to 500. Default 100.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "A page of the awards feed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AwardsPage"
                }
              }
            }
          },
          "400": {
            "description": "invalid_request or invalid_cursor: a parameter or the cursor is not valid. since_too_old (change feeds only): since is older than the feed history window; the detail names the earliest allowed since.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "401": {
            "description": "invalid_key, key_revoked or key_expired: the X-Api-Key header is missing, not valid, revoked or expired.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "403": {
            "description": "scope_missing, subscription_required, subscription_expired or plan_feature_required: the key or the organisation's plan does not allow this request.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "404": {
            "description": "not_found: the resource does not exist, or the Data API is not enabled.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "rate_limited (per key per minute, or too many requests in progress at once for one key) or quota_exceeded (per organisation per day). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "503": {
            "description": "service_unavailable: the API is temporarily unable to complete the request (it is at its limit of concurrent requests, the request took longer than the API allows, or a service it needs, such as supplier name search or usage counting, is unavailable or busy). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "500": {
            "description": "internal_error: the request failed because of a server error. Quote the traceId if you contact support.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        },
        "x-required-scope": [
          "awards:read"
        ]
      }
    },
    "/api/integration/v1/buyers": {
      "get": {
        "tags": [
          "Buyers"
        ],
        "summary": "Lists active buyers, optionally narrowed by name or by the slug of their TenderHub page.",
        "description": "Without name or slug, lists every active buyer. Send name or slug, not both. A slug can match more than one buyer.\nFollow nextCursor while hasMore is true, sending the same name or slug with every page.\n\nRequires scope: buyers:read.",
        "operationId": "BuyersSearch",
        "parameters": [
          {
            "name": "name",
            "in": "query",
            "description": "2 to 100 characters, matched anywhere in the buyer name, ignoring case.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "slug",
            "in": "query",
            "description": "The slug of a buyer page on the TenderHub website (/browse/buyers/<slug>), matched exactly.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "description": "The nextCursor value from the previous page, exactly as returned.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "description": "Maximum items per page, 1 to 100. Default 50.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "A page of buyers.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BuyerSearchPage"
                }
              }
            }
          },
          "400": {
            "description": "invalid_request or invalid_cursor: a parameter or the cursor is not valid. since_too_old (change feeds only): since is older than the feed history window; the detail names the earliest allowed since.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "401": {
            "description": "invalid_key, key_revoked or key_expired: the X-Api-Key header is missing, not valid, revoked or expired.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "403": {
            "description": "scope_missing, subscription_required, subscription_expired or plan_feature_required: the key or the organisation's plan does not allow this request.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "404": {
            "description": "not_found: the resource does not exist, or the Data API is not enabled.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "rate_limited (per key per minute, or too many requests in progress at once for one key) or quota_exceeded (per organisation per day). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "503": {
            "description": "service_unavailable: the API is temporarily unable to complete the request (it is at its limit of concurrent requests, the request took longer than the API allows, or a service it needs, such as supplier name search or usage counting, is unavailable or busy). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "500": {
            "description": "internal_error: the request failed because of a server error. Quote the traceId if you contact support.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        },
        "x-required-scope": [
          "buyers:read"
        ]
      }
    },
    "/api/integration/v1/buyers/{buyerId}": {
      "get": {
        "tags": [
          "Buyers"
        ],
        "summary": "Returns a buyer and the totals of its published opportunities and awards.",
        "description": "Requires scope: buyers:read.",
        "operationId": "BuyersGet",
        "parameters": [
          {
            "name": "buyerId",
            "in": "path",
            "description": "TenderHub buyer id, for example BUY-x7Pq2k, as returned by the buyer list or an opportunity.",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The buyer.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Buyer"
                }
              }
            }
          },
          "400": {
            "description": "invalid_request or invalid_cursor: a parameter or the cursor is not valid. since_too_old (change feeds only): since is older than the feed history window; the detail names the earliest allowed since.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "401": {
            "description": "invalid_key, key_revoked or key_expired: the X-Api-Key header is missing, not valid, revoked or expired.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "403": {
            "description": "scope_missing, subscription_required, subscription_expired or plan_feature_required: the key or the organisation's plan does not allow this request.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "404": {
            "description": "not_found: the resource does not exist, or the Data API is not enabled.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "rate_limited (per key per minute; this endpoint also has a lower limit of 30 requests per minute per key; or too many requests in progress at once for one key) or quota_exceeded (per organisation per day). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "503": {
            "description": "service_unavailable: the API is temporarily unable to complete the request (it is at its limit of concurrent requests, the request took longer than the API allows, or a service it needs, such as supplier name search or usage counting, is unavailable or busy). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "500": {
            "description": "internal_error: the request failed because of a server error. Quote the traceId if you contact support.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        },
        "x-required-scope": [
          "buyers:read"
        ]
      }
    },
    "/api/integration/v1/buyers/{buyerId}/awards": {
      "get": {
        "tags": [
          "Buyers"
        ],
        "summary": "Lists the opportunities a buyer awarded, newest award first, with every current award.",
        "description": "One item per opportunity. Follow nextCursor while hasMore is true, sending the same from and to with every page.\n\nRequires scope: buyers:read.",
        "operationId": "BuyersListAwards",
        "parameters": [
          {
            "name": "buyerId",
            "in": "path",
            "description": "TenderHub buyer id, for example BUY-x7Pq2k.",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "from",
            "in": "query",
            "description": "Only opportunities awarded at or after this instant (ISO-8601 UTC). Opportunities without an award date are then excluded.",
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "to",
            "in": "query",
            "description": "Only opportunities awarded before this instant (ISO-8601 UTC, exclusive). Opportunities without an award date are then excluded.",
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "description": "The nextCursor value from the previous page, exactly as returned.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "description": "Maximum items per page, 1 to 200. Default 50.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "A page of the buyer's awarded opportunities.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BuyerAwardsPage"
                }
              }
            }
          },
          "400": {
            "description": "invalid_request or invalid_cursor: a parameter or the cursor is not valid. since_too_old (change feeds only): since is older than the feed history window; the detail names the earliest allowed since.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "401": {
            "description": "invalid_key, key_revoked or key_expired: the X-Api-Key header is missing, not valid, revoked or expired.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "403": {
            "description": "scope_missing, subscription_required, subscription_expired or plan_feature_required: the key or the organisation's plan does not allow this request.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "404": {
            "description": "not_found: the resource does not exist, or the Data API is not enabled.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "rate_limited (per key per minute; this endpoint also has a lower limit of 30 requests per minute per key; or too many requests in progress at once for one key) or quota_exceeded (per organisation per day). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "503": {
            "description": "service_unavailable: the API is temporarily unable to complete the request (it is at its limit of concurrent requests, the request took longer than the API allows, or a service it needs, such as supplier name search or usage counting, is unavailable or busy). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "500": {
            "description": "internal_error: the request failed because of a server error. Quote the traceId if you contact support.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        },
        "x-required-scope": [
          "buyers:read"
        ]
      }
    },
    "/api/integration/v1/me": {
      "get": {
        "tags": [
          "Key"
        ],
        "summary": "Returns the organisation and API key making the request, and the limits that apply.",
        "description": "Needs no scope: any valid key can call it. Use it to check a key before polling the feeds.",
        "operationId": "IntegrationMeGet",
        "responses": {
          "200": {
            "description": "The key is valid and the organisation's plan includes API access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Me"
                }
              }
            }
          },
          "401": {
            "description": "invalid_key, key_revoked or key_expired: the X-Api-Key header is missing, not valid, revoked or expired.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "403": {
            "description": "scope_missing, subscription_required, subscription_expired or plan_feature_required: the key or the organisation's plan does not allow this request.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "404": {
            "description": "not_found: the resource does not exist, or the Data API is not enabled.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "rate_limited (per key per minute, or too many requests in progress at once for one key) or quota_exceeded (per organisation per day). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "503": {
            "description": "service_unavailable: the API is temporarily unable to complete the request (it is at its limit of concurrent requests, the request took longer than the API allows, or a service it needs, such as supplier name search or usage counting, is unavailable or busy). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "500": {
            "description": "internal_error: the request failed because of a server error. Quote the traceId if you contact support.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        }
      }
    },
    "/api/integration/v1/usage": {
      "get": {
        "tags": [
          "Key"
        ],
        "summary": "Returns today's request counts against the daily quota and the per-minute limit.",
        "description": "Needs no scope. Counts are for the current AEST day (the quota resets at midnight AEST). This request is counted\nbefore the counts are read. Keys are identified by their display prefix.",
        "operationId": "UsageGet",
        "responses": {
          "200": {
            "description": "The usage.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Usage"
                }
              }
            }
          },
          "401": {
            "description": "invalid_key, key_revoked or key_expired: the X-Api-Key header is missing, not valid, revoked or expired.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "403": {
            "description": "scope_missing, subscription_required, subscription_expired or plan_feature_required: the key or the organisation's plan does not allow this request.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "404": {
            "description": "not_found: the resource does not exist, or the Data API is not enabled.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "rate_limited (per key per minute, or too many requests in progress at once for one key) or quota_exceeded (per organisation per day). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "503": {
            "description": "service_unavailable: the API is temporarily unable to complete the request (it is at its limit of concurrent requests, the request took longer than the API allows, or a service it needs, such as supplier name search or usage counting, is unavailable or busy). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "500": {
            "description": "internal_error: the request failed because of a server error. Quote the traceId if you contact support.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        }
      }
    },
    "/api/integration/v1/opportunities": {
      "get": {
        "tags": [
          "Opportunities"
        ],
        "summary": "Lists opportunities that changed since a point in time, oldest change first.",
        "description": "Every opportunity is in this feed, and an item is its full current state. Start with since, then follow nextCursor\nwhile hasMore is true, sending the same category, state and location filters with every page. Pages may be short or\nempty while hasMore is true. Keep the last nextCursor and poll with it later to receive only newer changes.\nHistory is limited to 24 months: a change recorded earlier is never returned, even through an older cursor. A cursor\nis never refused for its age. If your last poll (or your cursor) is more than 24 months old, changes in the gap,\nincluding supplier hidden and deleted entries, cannot be delivered. To keep your copy accurate, we recommend that\nyou first re-verify every supplier you hold with GET /suppliers/{supplierId} (a 404 means it is no longer\npublished; that call needs suppliers:read), then resume from the earliest allowed since.\n\nRequires scope: opportunities:read.",
        "operationId": "OpportunitiesList",
        "parameters": [
          {
            "name": "since",
            "in": "query",
            "description": "Only changes recorded at or after this instant (ISO-8601 UTC, for example 2026-01-01T00:00:00Z). Required when no cursor is given. At most 24 months back: an older since is refused with 400 since_too_old, whose detail gives the earliest allowed value (midnight UTC on the same date 24 months ago).",
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "description": "The nextCursor value from the previous page, exactly as returned.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "description": "Maximum items per page, 1 to 500. Default 100.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "category",
            "in": "query",
            "description": "Only opportunities in this TenderHub category or any category under it (category slug, for example cleaning-janitorial-services, from GET /api/integration/v1/reference/categories).",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "state",
            "in": "query",
            "description": "Only opportunities in this state or territory (state code, for example nsw or nt, from GET /api/integration/v1/reference/states).",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "location",
            "in": "query",
            "description": "Only opportunities in this location (location slug, for example northern-territory, from GET /api/integration/v1/reference/locations).",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "A page of the opportunities feed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OpportunitiesPage"
                }
              }
            }
          },
          "400": {
            "description": "invalid_request or invalid_cursor: a parameter or the cursor is not valid. since_too_old (change feeds only): since is older than the feed history window; the detail names the earliest allowed since.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "401": {
            "description": "invalid_key, key_revoked or key_expired: the X-Api-Key header is missing, not valid, revoked or expired.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "403": {
            "description": "scope_missing, subscription_required, subscription_expired or plan_feature_required: the key or the organisation's plan does not allow this request.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "404": {
            "description": "not_found: the resource does not exist, or the Data API is not enabled.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "rate_limited (per key per minute, or too many requests in progress at once for one key) or quota_exceeded (per organisation per day). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "503": {
            "description": "service_unavailable: the API is temporarily unable to complete the request (it is at its limit of concurrent requests, the request took longer than the API allows, or a service it needs, such as supplier name search or usage counting, is unavailable or busy). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "500": {
            "description": "internal_error: the request failed because of a server error. Quote the traceId if you contact support.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        },
        "x-required-scope": [
          "opportunities:read"
        ]
      }
    },
    "/api/integration/v1/opportunities/{ref}": {
      "get": {
        "tags": [
          "Opportunities"
        ],
        "summary": "Returns one opportunity by its TenderHub reference.",
        "description": "The same shape as an item of the opportunities feed. Use it to refresh one record or to resolve a reference you were given.\n\nRequires scope: opportunities:read.",
        "operationId": "OpportunitiesGet",
        "parameters": [
          {
            "name": "ref",
            "in": "path",
            "description": "TenderHub reference of the opportunity, for example TH-abc123, exactly as returned by the API.",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The opportunity.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OpportunityItem"
                }
              }
            }
          },
          "400": {
            "description": "invalid_request or invalid_cursor: a parameter or the cursor is not valid. since_too_old (change feeds only): since is older than the feed history window; the detail names the earliest allowed since.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "401": {
            "description": "invalid_key, key_revoked or key_expired: the X-Api-Key header is missing, not valid, revoked or expired.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "403": {
            "description": "scope_missing, subscription_required, subscription_expired or plan_feature_required: the key or the organisation's plan does not allow this request.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "404": {
            "description": "not_found: the resource does not exist, or the Data API is not enabled.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "rate_limited (per key per minute, or too many requests in progress at once for one key) or quota_exceeded (per organisation per day). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "503": {
            "description": "service_unavailable: the API is temporarily unable to complete the request (it is at its limit of concurrent requests, the request took longer than the API allows, or a service it needs, such as supplier name search or usage counting, is unavailable or busy). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "500": {
            "description": "internal_error: the request failed because of a server error. Quote the traceId if you contact support.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        },
        "x-required-scope": [
          "opportunities:read"
        ]
      }
    },
    "/api/integration/v1/reference/categories": {
      "get": {
        "tags": [
          "Reference"
        ],
        "summary": "Lists every TenderHub category.",
        "description": "Top-level categories first in name order, then sub-categories in name order. Needs no scope.",
        "operationId": "ReferenceCategories",
        "responses": {
          "200": {
            "description": "The categories.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CategoryList"
                }
              }
            }
          },
          "401": {
            "description": "invalid_key, key_revoked or key_expired: the X-Api-Key header is missing, not valid, revoked or expired.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "403": {
            "description": "scope_missing, subscription_required, subscription_expired or plan_feature_required: the key or the organisation's plan does not allow this request.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "404": {
            "description": "not_found: the resource does not exist, or the Data API is not enabled.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "rate_limited (per key per minute, or too many requests in progress at once for one key) or quota_exceeded (per organisation per day). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "503": {
            "description": "service_unavailable: the API is temporarily unable to complete the request (it is at its limit of concurrent requests, the request took longer than the API allows, or a service it needs, such as supplier name search or usage counting, is unavailable or busy). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "500": {
            "description": "internal_error: the request failed because of a server error. Quote the traceId if you contact support.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        }
      }
    },
    "/api/integration/v1/reference/locations": {
      "get": {
        "tags": [
          "Reference"
        ],
        "summary": "Lists every location, one per slug.",
        "description": "Needs no scope.",
        "operationId": "ReferenceLocations",
        "responses": {
          "200": {
            "description": "The locations.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LocationList"
                }
              }
            }
          },
          "401": {
            "description": "invalid_key, key_revoked or key_expired: the X-Api-Key header is missing, not valid, revoked or expired.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "403": {
            "description": "scope_missing, subscription_required, subscription_expired or plan_feature_required: the key or the organisation's plan does not allow this request.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "404": {
            "description": "not_found: the resource does not exist, or the Data API is not enabled.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "rate_limited (per key per minute, or too many requests in progress at once for one key) or quota_exceeded (per organisation per day). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "503": {
            "description": "service_unavailable: the API is temporarily unable to complete the request (it is at its limit of concurrent requests, the request took longer than the API allows, or a service it needs, such as supplier name search or usage counting, is unavailable or busy). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "500": {
            "description": "internal_error: the request failed because of a server error. Quote the traceId if you contact support.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        }
      }
    },
    "/api/integration/v1/reference/states": {
      "get": {
        "tags": [
          "Reference"
        ],
        "summary": "Lists every state and territory code.",
        "description": "Needs no scope.",
        "operationId": "ReferenceStates",
        "responses": {
          "200": {
            "description": "The states.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/StateList"
                }
              }
            }
          },
          "401": {
            "description": "invalid_key, key_revoked or key_expired: the X-Api-Key header is missing, not valid, revoked or expired.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "403": {
            "description": "scope_missing, subscription_required, subscription_expired or plan_feature_required: the key or the organisation's plan does not allow this request.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "404": {
            "description": "not_found: the resource does not exist, or the Data API is not enabled.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "rate_limited (per key per minute, or too many requests in progress at once for one key) or quota_exceeded (per organisation per day). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "503": {
            "description": "service_unavailable: the API is temporarily unable to complete the request (it is at its limit of concurrent requests, the request took longer than the API allows, or a service it needs, such as supplier name search or usage counting, is unavailable or busy). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "500": {
            "description": "internal_error: the request failed because of a server error. Quote the traceId if you contact support.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        }
      }
    },
    "/api/integration/v1/reference/statuses": {
      "get": {
        "tags": [
          "Reference"
        ],
        "summary": "Lists every opportunity status.",
        "description": "Needs no scope.",
        "operationId": "ReferenceStatuses",
        "responses": {
          "200": {
            "description": "The statuses.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/StatusList"
                }
              }
            }
          },
          "401": {
            "description": "invalid_key, key_revoked or key_expired: the X-Api-Key header is missing, not valid, revoked or expired.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "403": {
            "description": "scope_missing, subscription_required, subscription_expired or plan_feature_required: the key or the organisation's plan does not allow this request.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "404": {
            "description": "not_found: the resource does not exist, or the Data API is not enabled.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "rate_limited (per key per minute, or too many requests in progress at once for one key) or quota_exceeded (per organisation per day). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "503": {
            "description": "service_unavailable: the API is temporarily unable to complete the request (it is at its limit of concurrent requests, the request took longer than the API allows, or a service it needs, such as supplier name search or usage counting, is unavailable or busy). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "500": {
            "description": "internal_error: the request failed because of a server error. Quote the traceId if you contact support.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        }
      }
    },
    "/api/integration/v1/reference/opportunity-types": {
      "get": {
        "tags": [
          "Reference"
        ],
        "summary": "Lists every opportunity type.",
        "description": "Needs no scope.",
        "operationId": "ReferenceOpportunityTypes",
        "responses": {
          "200": {
            "description": "The opportunity types.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OpportunityTypeList"
                }
              }
            }
          },
          "401": {
            "description": "invalid_key, key_revoked or key_expired: the X-Api-Key header is missing, not valid, revoked or expired.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "403": {
            "description": "scope_missing, subscription_required, subscription_expired or plan_feature_required: the key or the organisation's plan does not allow this request.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "404": {
            "description": "not_found: the resource does not exist, or the Data API is not enabled.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "rate_limited (per key per minute, or too many requests in progress at once for one key) or quota_exceeded (per organisation per day). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "503": {
            "description": "service_unavailable: the API is temporarily unable to complete the request (it is at its limit of concurrent requests, the request took longer than the API allows, or a service it needs, such as supplier name search or usage counting, is unavailable or busy). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "500": {
            "description": "internal_error: the request failed because of a server error. Quote the traceId if you contact support.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        }
      }
    },
    "/api/integration/v1/suppliers/changes": {
      "get": {
        "tags": [
          "Suppliers"
        ],
        "summary": "Lists suppliers that changed since a point in time, oldest change first.",
        "description": "One item per supplier, carrying its latest change: a supplier record change (name, ABN, website, page), the\nsupplier being hidden, unhidden, merged into another supplier or deleted, or its set of awards changing. Hidden\nand deleted items carry only id, change and changedAt. Start with since, then follow nextCursor\nwhile hasMore is true. Pages may be short or empty while hasMore is true. Keep the last nextCursor and poll with it\nlater to receive only newer changes.\nHistory is limited to 24 months: a change recorded earlier is never returned, even through an older cursor. A cursor\nis never refused for its age. If your last poll (or your cursor) is more than 24 months old, changes in the gap,\nincluding supplier hidden and deleted entries, cannot be delivered. To keep your copy accurate, we recommend that\nyou first re-verify every supplier you hold with GET /suppliers/{supplierId} (a 404 means it is no longer\npublished; that call needs suppliers:read), then resume from the earliest allowed since.\nAny key holding awards:read, buyers:read or suppliers:read may read this feed: supplier names reach you through all\nthree, so each of them can receive the hidden and deleted entries. The supplier record itself is\nreturned only to a key holding suppliers:read; for any other key supplier is always null and each item carries only\nid, change, changedAt and mergedInto.\n\nRequires any one of these scopes: awards:read, buyers:read or suppliers:read.",
        "operationId": "SupplierChangesList",
        "parameters": [
          {
            "name": "since",
            "in": "query",
            "description": "Only changes recorded at or after this instant (ISO-8601 UTC, for example 2026-01-01T00:00:00Z). Required when no cursor is given. At most 24 months back: an older since is refused with 400 since_too_old, whose detail gives the earliest allowed value (midnight UTC on the same date 24 months ago).",
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "description": "The nextCursor value from the previous page, exactly as returned.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "description": "Maximum items per page, 1 to 500. Default 100.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "A page of the supplier change feed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SupplierChangesPage"
                }
              }
            }
          },
          "400": {
            "description": "invalid_request or invalid_cursor: a parameter or the cursor is not valid. since_too_old (change feeds only): since is older than the feed history window; the detail names the earliest allowed since.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "401": {
            "description": "invalid_key, key_revoked or key_expired: the X-Api-Key header is missing, not valid, revoked or expired.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "403": {
            "description": "scope_missing, subscription_required, subscription_expired or plan_feature_required: the key or the organisation's plan does not allow this request.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "404": {
            "description": "not_found: the resource does not exist, or the Data API is not enabled.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "rate_limited (per key per minute, or too many requests in progress at once for one key) or quota_exceeded (per organisation per day). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "503": {
            "description": "service_unavailable: the API is temporarily unable to complete the request (it is at its limit of concurrent requests, the request took longer than the API allows, or a service it needs, such as supplier name search or usage counting, is unavailable or busy). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "500": {
            "description": "internal_error: the request failed because of a server error. Quote the traceId if you contact support.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        },
        "x-required-scope": [
          "awards:read",
          "buyers:read",
          "suppliers:read"
        ]
      }
    },
    "/api/integration/v1/suppliers": {
      "get": {
        "tags": [
          "Suppliers"
        ],
        "summary": "Finds suppliers by ABN, by name or by slug.",
        "description": "Send exactly one of abn, name or slug. abn and slug are exact matches, returned in name order. name is a ranked\nsearch: best match first (an exact name, then names starting with your words, then names containing all of them),\nties in a fixed order. Follow nextCursor while hasMore is true, sending the same criterion with every page. This is\na lookup, not a bulk export: to keep a copy of suppliers current, use the supplier change feed. Store the returned\nid (SUP-...), not the name or slug, which can change.\n\nRequires scope: suppliers:read.",
        "operationId": "SuppliersSearch",
        "parameters": [
          {
            "name": "abn",
            "in": "query",
            "description": "Australian Business Number, 11 digits. Spaces are ignored.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "name",
            "in": "query",
            "description": "Words of the supplier name, 2 to 100 characters, case-insensitive. Whole words match in any order; typed in order, the last word may also be the start of a word (acme buil finds Acme Builders Pty Ltd).",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "slug",
            "in": "query",
            "description": "The supplier's slug on the TenderHub website, exactly.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "description": "The nextCursor value from the previous page, exactly as returned.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "description": "Maximum items per page, 1 to 50. Default 20.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "A page of matching suppliers. Empty when nothing matches.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SupplierSearchPage"
                }
              }
            }
          },
          "400": {
            "description": "invalid_request or invalid_cursor: a parameter or the cursor is not valid. since_too_old (change feeds only): since is older than the feed history window; the detail names the earliest allowed since.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "401": {
            "description": "invalid_key, key_revoked or key_expired: the X-Api-Key header is missing, not valid, revoked or expired.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "403": {
            "description": "scope_missing, subscription_required, subscription_expired or plan_feature_required: the key or the organisation's plan does not allow this request.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "404": {
            "description": "not_found: the resource does not exist, or the Data API is not enabled.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "rate_limited (per key per minute, or too many requests in progress at once for one key) or quota_exceeded (per organisation per day). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "503": {
            "description": "service_unavailable: the API is temporarily unable to complete the request (it is at its limit of concurrent requests, the request took longer than the API allows, or a service it needs, such as supplier name search or usage counting, is unavailable or busy). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "500": {
            "description": "internal_error: the request failed because of a server error. Quote the traceId if you contact support.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        },
        "x-required-scope": [
          "suppliers:read"
        ]
      }
    },
    "/api/integration/v1/suppliers/{supplierId}": {
      "get": {
        "tags": [
          "Suppliers"
        ],
        "summary": "Returns a supplier and the totals of its recorded awards.",
        "description": "Requires scope: suppliers:read.",
        "operationId": "SuppliersGet",
        "parameters": [
          {
            "name": "supplierId",
            "in": "path",
            "description": "TenderHub supplier id, for example SUP-x9Yz12, as returned in an award.",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The supplier.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Supplier"
                }
              }
            }
          },
          "400": {
            "description": "invalid_request or invalid_cursor: a parameter or the cursor is not valid. since_too_old (change feeds only): since is older than the feed history window; the detail names the earliest allowed since.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "401": {
            "description": "invalid_key, key_revoked or key_expired: the X-Api-Key header is missing, not valid, revoked or expired.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "403": {
            "description": "scope_missing, subscription_required, subscription_expired or plan_feature_required: the key or the organisation's plan does not allow this request.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "404": {
            "description": "not_found: the resource does not exist, or the Data API is not enabled.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "rate_limited (per key per minute; this endpoint also has a lower limit of 30 requests per minute per key; or too many requests in progress at once for one key) or quota_exceeded (per organisation per day). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "503": {
            "description": "service_unavailable: the API is temporarily unable to complete the request (it is at its limit of concurrent requests, the request took longer than the API allows, or a service it needs, such as supplier name search or usage counting, is unavailable or busy). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "500": {
            "description": "internal_error: the request failed because of a server error. Quote the traceId if you contact support.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        },
        "x-required-scope": [
          "suppliers:read"
        ]
      }
    },
    "/api/integration/v1/suppliers/{supplierId}/awards": {
      "get": {
        "tags": [
          "Suppliers"
        ],
        "summary": "Lists the opportunities awarded to a supplier, newest award first.",
        "description": "One item per opportunity. Follow nextCursor while hasMore is true, sending the same from and to with every page.\n\nRequires scope: suppliers:read.",
        "operationId": "SuppliersListAwards",
        "parameters": [
          {
            "name": "supplierId",
            "in": "path",
            "description": "TenderHub supplier id, for example SUP-x9Yz12, as returned in an award.",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "from",
            "in": "query",
            "description": "Only awards made at or after this instant (ISO-8601 UTC). Awards without a date are then excluded.",
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "to",
            "in": "query",
            "description": "Only awards made before this instant (ISO-8601 UTC, exclusive). Awards without a date are then excluded.",
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "description": "The nextCursor value from the previous page, exactly as returned.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "description": "Maximum items per page, 1 to 200. Default 50.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "A page of the supplier's awards.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SupplierAwardsPage"
                }
              }
            }
          },
          "400": {
            "description": "invalid_request or invalid_cursor: a parameter or the cursor is not valid. since_too_old (change feeds only): since is older than the feed history window; the detail names the earliest allowed since.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "401": {
            "description": "invalid_key, key_revoked or key_expired: the X-Api-Key header is missing, not valid, revoked or expired.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "403": {
            "description": "scope_missing, subscription_required, subscription_expired or plan_feature_required: the key or the organisation's plan does not allow this request.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "404": {
            "description": "not_found: the resource does not exist, or the Data API is not enabled.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "429": {
            "description": "rate_limited (per key per minute; this endpoint also has a lower limit of 30 requests per minute per key; or too many requests in progress at once for one key) or quota_exceeded (per organisation per day). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "503": {
            "description": "service_unavailable: the API is temporarily unable to complete the request (it is at its limit of concurrent requests, the request took longer than the API allows, or a service it needs, such as supplier name search or usage counting, is unavailable or busy). Retry after the Retry-After header.",
            "headers": {
              "Retry-After": {
                "description": "Seconds to wait before retrying.",
                "schema": {
                  "type": "integer"
                }
              }
            },
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          },
          "500": {
            "description": "internal_error: the request failed because of a server error. Quote the traceId if you contact support.",
            "content": {
              "application/problem+json": {
                "schema": {
                  "$ref": "#/components/schemas/Problem"
                }
              }
            }
          }
        },
        "x-required-scope": [
          "suppliers:read"
        ]
      }
    }
  },
  "components": {
    "schemas": {
      "Award": {
        "type": "object",
        "properties": {
          "supplier": {
            "allOf": [
              {
                "$ref": "#/components/schemas/SupplierRef"
              }
            ],
            "description": "The supplier. Null when the awardee could not be matched to a TenderHub supplier record, or the supplier record is\nnot public. The value and date are still given.",
            "nullable": true
          },
          "value": {
            "type": "number",
            "description": "Value awarded to this supplier in AUD (the sum of its award rows for the opportunity). When a source publishes one\ntotal for several suppliers it is split evenly between them. Null when the source did not publish a value.",
            "format": "double",
            "nullable": true
          },
          "awardedAt": {
            "type": "string",
            "description": "When this supplier's award was made (UTC). Null when not published.",
            "format": "date-time",
            "nullable": true
          }
        },
        "additionalProperties": false,
        "description": "One supplier's share of an award."
      },
      "AwardItem": {
        "required": [
          "awards",
          "categories",
          "changedAt",
          "locations",
          "opportunity",
          "timeZone"
        ],
        "type": "object",
        "properties": {
          "opportunity": {
            "$ref": "#/components/schemas/OpportunityRef"
          },
          "buyer": {
            "allOf": [
              {
                "$ref": "#/components/schemas/BuyerRef"
              }
            ],
            "description": "The buying organisation. Null when the source did not name one.",
            "nullable": true
          },
          "status": {
            "allOf": [
              {
                "$ref": "#/components/schemas/Status"
              }
            ],
            "description": "The opportunity's current TenderHub status. Null when not mapped.",
            "nullable": true
          },
          "awardedAt": {
            "type": "string",
            "description": "When the opportunity was awarded (UTC): the published award date, else the latest award row date. Null when unknown.",
            "format": "date-time",
            "nullable": true
          },
          "timeZone": {
            "type": "string",
            "description": "The source's time zone (Windows id, for example AUS Eastern Standard Time), to show dates as the buyer published them."
          },
          "totalValue": {
            "type": "number",
            "description": "Total awarded value of the opportunity in AUD, as published by the buyer. Null when the source did not publish a value.",
            "format": "double",
            "nullable": true
          },
          "categories": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Category"
            },
            "description": "TenderHub categories of the opportunity (the most specific category per branch)."
          },
          "locations": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Location"
            },
            "description": "Locations the opportunity applies to."
          },
          "awards": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Award"
            },
            "description": "Every current award of the opportunity, one per supplier. Empty when the award was withdrawn."
          },
          "changedAt": {
            "type": "string",
            "description": "When TenderHub recorded the change that put this item in the feed (UTC).",
            "format": "date-time"
          }
        },
        "additionalProperties": false,
        "description": "An opportunity with award history. Awards is the COMPLETE current set for the opportunity: replace what you stored\nfor it. An amended award re-emits the item; a withdrawn award re-emits it with an empty awards list."
      },
      "AwardsPage": {
        "required": [
          "hasMore",
          "items",
          "limit",
          "nextCursor"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/AwardItem"
            },
            "description": "Opportunities whose awards changed, in change order. A page may be short or empty while hasMore is true."
          },
          "nextCursor": {
            "type": "string",
            "description": "Pass this as cursor to get the next page. Always present: keep the last value and poll with it later to receive\nonly newer changes."
          },
          "hasMore": {
            "type": "boolean",
            "description": "True when more changes are available now. Keep following nextCursor while this is true."
          },
          "limit": {
            "type": "integer",
            "description": "The page size that was applied.",
            "format": "int32"
          }
        },
        "additionalProperties": false,
        "description": "One page of the awards feed, oldest change first."
      },
      "Buyer": {
        "required": [
          "awardCount",
          "id",
          "name",
          "opportunityCount",
          "slug"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "TenderHub buyer id, for example BUY-x7Pq2k. Opaque and stable: store this, not the name or slug."
          },
          "name": {
            "type": "string",
            "description": "Name of the buying organisation."
          },
          "slug": {
            "type": "string",
            "description": "The buyer's slug on the TenderHub website. It changes when the name changes: use id as the key."
          },
          "tenderHubUrl": {
            "type": "string",
            "description": "The buyer's page on the TenderHub website.",
            "nullable": true
          },
          "opportunityCount": {
            "type": "integer",
            "description": "Opportunities TenderHub has recorded for this buyer.",
            "format": "int32"
          },
          "awardCount": {
            "type": "integer",
            "description": "Of those, the opportunities that have been awarded.",
            "format": "int32"
          },
          "totalAwardedValue": {
            "type": "number",
            "description": "Total awarded value of the awarded opportunities in AUD, as published. Opportunities without a published value are\nleft out of the total. Null when the source did not publish a value for any of them.",
            "format": "double",
            "nullable": true
          },
          "firstAwardedAt": {
            "type": "string",
            "description": "When the buyer's earliest recorded award was made (UTC). Null when unknown.",
            "format": "date-time",
            "nullable": true
          },
          "lastAwardedAt": {
            "type": "string",
            "description": "When the buyer's latest recorded award was made (UTC). Null when unknown.",
            "format": "date-time",
            "nullable": true
          }
        },
        "additionalProperties": false,
        "description": "A buying organisation and the totals of its published opportunities and awards."
      },
      "BuyerAwardItem": {
        "required": [
          "awards",
          "categories",
          "locations",
          "opportunity",
          "timeZone"
        ],
        "type": "object",
        "properties": {
          "opportunity": {
            "$ref": "#/components/schemas/OpportunityRef"
          },
          "status": {
            "allOf": [
              {
                "$ref": "#/components/schemas/Status"
              }
            ],
            "description": "The opportunity's current TenderHub status. Null when not mapped.",
            "nullable": true
          },
          "awardedAt": {
            "type": "string",
            "description": "When the opportunity was awarded (UTC): the published award date, else the latest award row date. Null when unknown.",
            "format": "date-time",
            "nullable": true
          },
          "timeZone": {
            "type": "string",
            "description": "The source's time zone (Windows id, for example AUS Eastern Standard Time), to show dates as the buyer published them."
          },
          "totalValue": {
            "type": "number",
            "description": "Total awarded value of the opportunity in AUD, as published by the buyer. Null when the source did not publish a value.",
            "format": "double",
            "nullable": true
          },
          "categories": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Category"
            },
            "description": "TenderHub categories of the opportunity."
          },
          "locations": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Location"
            },
            "description": "Locations the opportunity applies to."
          },
          "awards": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Award"
            },
            "description": "Every current award of the opportunity, one per supplier."
          }
        },
        "additionalProperties": false,
        "description": "An opportunity the buyer awarded, with every current award (one per supplier). A page item, named like AwardItem and\nSupplierAwardItem (schema id BuyerAwardItem), not to be confused with Award (one supplier's award)."
      },
      "BuyerAwardsPage": {
        "required": [
          "hasMore",
          "items",
          "limit"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/BuyerAwardItem"
            },
            "description": "The buyer's awarded opportunities, newest award first. Opportunities without an award date come last."
          },
          "nextCursor": {
            "type": "string",
            "description": "Pass this as cursor (with the same from and to) to get the next page. Null when there are no more pages.",
            "nullable": true
          },
          "hasMore": {
            "type": "boolean",
            "description": "True when another page is available."
          },
          "limit": {
            "type": "integer",
            "description": "The page size that was applied.",
            "format": "int32"
          }
        },
        "additionalProperties": false,
        "description": "One page of a buyer's awarded opportunities, newest award first."
      },
      "BuyerRef": {
        "required": [
          "id",
          "name",
          "slug"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "TenderHub buyer id, for example BUY-x9Yz12. Opaque and stable: store it as a string. Pass it to GET /api/integration/v1/buyers/{buyerId}."
          },
          "name": {
            "type": "string",
            "description": "Name of the buying organisation, for example Department of Defence."
          },
          "slug": {
            "type": "string",
            "description": "The buyer's slug on the TenderHub website, for example department-of-defence. Changes when the name changes: key on id, not on slug."
          }
        },
        "additionalProperties": false,
        "description": "The buying organisation, as referenced from an opportunity or award."
      },
      "BuyerSearchPage": {
        "required": [
          "hasMore",
          "items",
          "limit"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/BuyerSummary"
            },
            "description": "Buyers matching the request, in name order."
          },
          "nextCursor": {
            "type": "string",
            "description": "Pass this as cursor (with the same name or slug) to get the next page. Null when there are no more pages.",
            "nullable": true
          },
          "hasMore": {
            "type": "boolean",
            "description": "True when another page is available."
          },
          "limit": {
            "type": "integer",
            "description": "The page size that was applied.",
            "format": "int32"
          }
        },
        "additionalProperties": false,
        "description": "One page of buyers, in name order."
      },
      "BuyerSummary": {
        "required": [
          "id",
          "name",
          "slug"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "TenderHub buyer id, for example BUY-x7Pq2k. Opaque and stable: store this, not the name or slug."
          },
          "name": {
            "type": "string",
            "description": "Name of the buying organisation, for example Department of Defence."
          },
          "slug": {
            "type": "string",
            "description": "The buyer's slug on the TenderHub website. It changes when the name changes: use id as the key."
          },
          "tenderHubUrl": {
            "type": "string",
            "description": "The buyer's page on the TenderHub website.",
            "nullable": true
          }
        },
        "additionalProperties": false,
        "description": "A buying organisation."
      },
      "Category": {
        "required": [
          "name",
          "slug"
        ],
        "type": "object",
        "properties": {
          "slug": {
            "type": "string",
            "description": "The category's slug on the TenderHub website, for example cleaning-janitorial-services. Use it as the category filter; GET /api/integration/v1/reference/categories lists them."
          },
          "name": {
            "type": "string",
            "description": "Category name, for example Cleaning & janitorial services."
          },
          "parentSlug": {
            "type": "string",
            "description": "Slug of the parent category. Null for a top-level category.",
            "nullable": true
          }
        },
        "additionalProperties": false,
        "description": "A TenderHub category the opportunity is classified under, as used on the TenderHub website."
      },
      "CategoryList": {
        "required": [
          "items"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ReferenceCategory"
            },
            "description": "The categories."
          }
        },
        "additionalProperties": false,
        "description": "Every TenderHub category: roots first in name order, then sub-categories in name order."
      },
      "Location": {
        "required": [
          "name",
          "slug",
          "state"
        ],
        "type": "object",
        "properties": {
          "slug": {
            "type": "string",
            "description": "The location's slug on the TenderHub website, for example northern-territory. Use it as the location filter; GET /api/integration/v1/reference/locations lists them."
          },
          "name": {
            "type": "string",
            "description": "Location name, for example Northern Territory."
          },
          "state": {
            "type": "string",
            "description": "State or territory code, for example nt. GET /api/integration/v1/reference/states lists them."
          }
        },
        "additionalProperties": false,
        "description": "A location the opportunity applies to."
      },
      "LocationList": {
        "required": [
          "items"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Location"
            },
            "description": "The locations, in name order."
          }
        },
        "additionalProperties": false,
        "description": "Every location, one per slug."
      },
      "Me": {
        "required": [
          "key",
          "organisation",
          "rateLimit"
        ],
        "type": "object",
        "properties": {
          "organisation": {
            "$ref": "#/components/schemas/MeOrganisation"
          },
          "key": {
            "$ref": "#/components/schemas/MeKey"
          },
          "rateLimit": {
            "$ref": "#/components/schemas/MeRateLimit"
          }
        },
        "additionalProperties": false,
        "description": "The organisation and API key making the request, and the limits that apply to it."
      },
      "MeKey": {
        "required": [
          "displayPrefix",
          "scopes"
        ],
        "type": "object",
        "properties": {
          "displayPrefix": {
            "type": "string",
            "description": "The start of the key (thub_live_ plus 6 characters), as shown on the API access page. It identifies the key; it is not the secret."
          },
          "scopes": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Scopes granted to the key, for example awards:read. Each endpoint needs one of them."
          },
          "expiresAt": {
            "type": "string",
            "description": "When the key stops working (UTC). Null when the key does not expire.",
            "format": "date-time",
            "nullable": true
          }
        },
        "additionalProperties": false,
        "description": "The API key used for the request."
      },
      "MeOrganisation": {
        "required": [
          "name"
        ],
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "Organisation name as registered with TenderHub."
          }
        },
        "additionalProperties": false,
        "description": "The organisation that owns the API key."
      },
      "MeRateLimit": {
        "required": [
          "perDay",
          "perMinute"
        ],
        "type": "object",
        "properties": {
          "perMinute": {
            "type": "integer",
            "description": "Requests allowed per key per minute.",
            "format": "int32"
          },
          "perDay": {
            "type": "integer",
            "description": "Requests allowed per organisation per day (all of its keys together), resetting at midnight AEST.",
            "format": "int32"
          }
        },
        "additionalProperties": false,
        "description": "Request limits. Current usage is reported on every response in the RateLimit-* and X-Daily-Quota-* headers."
      },
      "OpportunitiesPage": {
        "required": [
          "hasMore",
          "items",
          "limit",
          "nextCursor"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/OpportunityItem"
            },
            "description": "Opportunities that changed, in change order. A page may be short or empty while hasMore is true."
          },
          "nextCursor": {
            "type": "string",
            "description": "Pass this as cursor to get the next page. Always present: keep the last value and poll with it later to receive\nonly newer changes. Send the same category, state and location filters with every page."
          },
          "hasMore": {
            "type": "boolean",
            "description": "True when more changes are available now. Keep following nextCursor while this is true."
          },
          "limit": {
            "type": "integer",
            "description": "The page size that was applied.",
            "format": "int32"
          }
        },
        "additionalProperties": false,
        "description": "One page of the opportunities feed, oldest change first."
      },
      "OpportunityItem": {
        "required": [
          "categories",
          "changedAt",
          "locations",
          "ref",
          "sourceReference",
          "sourceUrl",
          "tenderHubUrl",
          "timeZone",
          "title"
        ],
        "type": "object",
        "properties": {
          "ref": {
            "type": "string",
            "description": "TenderHub reference of the opportunity, for example TH-abc123. Opaque: store it as a string."
          },
          "title": {
            "type": "string",
            "description": "Title of the opportunity as published by the buyer."
          },
          "sourceReference": {
            "type": "string",
            "description": "The buyer's own reference for the opportunity."
          },
          "type": {
            "allOf": [
              {
                "$ref": "#/components/schemas/OpportunityType"
              }
            ],
            "description": "Type of opportunity, for example request_for_tender (Request for Tender). Null when not mapped.",
            "nullable": true
          },
          "status": {
            "allOf": [
              {
                "$ref": "#/components/schemas/Status"
              }
            ],
            "description": "The opportunity's current TenderHub status. Null when not mapped.",
            "nullable": true
          },
          "buyer": {
            "allOf": [
              {
                "$ref": "#/components/schemas/BuyerRef"
              }
            ],
            "description": "The buying organisation. Null when the source did not name one.",
            "nullable": true
          },
          "openAt": {
            "type": "string",
            "description": "When the opportunity opened (UTC).",
            "format": "date-time",
            "nullable": true
          },
          "closeAt": {
            "type": "string",
            "description": "When the opportunity closes (UTC).",
            "format": "date-time",
            "nullable": true
          },
          "closeTimeIsExplicit": {
            "type": "boolean",
            "description": "True when the source published a closing time; false when only a closing date was published.",
            "nullable": true
          },
          "cancelledAt": {
            "type": "string",
            "description": "When the opportunity was cancelled (UTC). Null unless cancelled.",
            "format": "date-time",
            "nullable": true
          },
          "awardedAt": {
            "type": "string",
            "description": "When the opportunity was awarded (UTC). Null unless awarded.",
            "format": "date-time",
            "nullable": true
          },
          "expectedReleaseDate": {
            "type": "string",
            "description": "For a planned opportunity, when the buyer expects to release it (UTC).",
            "format": "date-time",
            "nullable": true
          },
          "timeZone": {
            "type": "string",
            "description": "The source's time zone (Windows id, for example AUS Eastern Standard Time), to show dates as the buyer published them."
          },
          "estimatedValue": {
            "allOf": [
              {
                "$ref": "#/components/schemas/ValueRange"
              }
            ],
            "description": "The buyer's estimated value range in AUD. Null when the source did not publish a value.",
            "nullable": true
          },
          "awardedTotalValue": {
            "type": "number",
            "description": "Total awarded value in AUD. Null when the source did not publish a value (or the opportunity is not awarded).",
            "format": "double",
            "nullable": true
          },
          "categories": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Category"
            },
            "description": "TenderHub categories of the opportunity (the most specific category per branch)."
          },
          "locations": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Location"
            },
            "description": "Locations the opportunity applies to."
          },
          "sourceUrl": {
            "type": "string",
            "description": "Link to the opportunity on the buyer's own tender portal."
          },
          "tenderHubUrl": {
            "type": "string",
            "description": "Link to the opportunity on the TenderHub website."
          },
          "changedAt": {
            "type": "string",
            "description": "When TenderHub recorded the change that put this item in the feed (UTC). For GET /opportunities/{ref}, the last\nrecorded change to the opportunity.",
            "format": "date-time"
          }
        },
        "additionalProperties": false,
        "description": "The current state of an opportunity (tender, quote request, expression of interest and so on)."
      },
      "OpportunityRef": {
        "required": [
          "ref",
          "sourceReference",
          "tenderHubUrl",
          "title"
        ],
        "type": "object",
        "properties": {
          "ref": {
            "type": "string",
            "description": "TenderHub reference of the opportunity, for example TH-abc123. Opaque: store it as a string."
          },
          "title": {
            "type": "string",
            "description": "Title of the opportunity as published by the buyer."
          },
          "sourceReference": {
            "type": "string",
            "description": "The buyer's own reference for the opportunity, for example ATM 2026/123."
          },
          "tenderHubUrl": {
            "type": "string",
            "description": "Link to the opportunity on the TenderHub website."
          }
        },
        "additionalProperties": false,
        "description": "The opportunity an item is about."
      },
      "OpportunityType": {
        "required": [
          "code",
          "name"
        ],
        "type": "object",
        "properties": {
          "code": {
            "type": "string",
            "description": "Stable type code, for example request_for_tender or expression_of_interest. Match on this value; GET /api/integration/v1/reference/opportunity-types lists them."
          },
          "name": {
            "type": "string",
            "description": "Display name of the type, for example Request for Tender. May change: match on code."
          }
        },
        "additionalProperties": false,
        "description": "The type of an opportunity."
      },
      "OpportunityTypeList": {
        "required": [
          "items"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/OpportunityType"
            },
            "description": "The opportunity types, in name order."
          }
        },
        "additionalProperties": false,
        "description": "Every opportunity type."
      },
      "Problem": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string"
          },
          "title": {
            "type": "string"
          },
          "status": {
            "type": "integer",
            "format": "int32"
          },
          "code": {
            "type": "string"
          },
          "detail": {
            "type": "string"
          },
          "traceId": {
            "type": "string"
          }
        },
        "additionalProperties": false,
        "description": "The problem+json body (RFC 9457 members plus `code` and `traceId`)."
      },
      "ReferenceCategory": {
        "required": [
          "name",
          "slug"
        ],
        "type": "object",
        "properties": {
          "slug": {
            "type": "string",
            "description": "Stable identifier of the category, as used in its TenderHub page address, for example ict-software-digital. Use it as the category filter."
          },
          "name": {
            "type": "string",
            "description": "Display name of the category."
          },
          "parentSlug": {
            "type": "string",
            "description": "Slug of the parent category. Null for a top-level category.",
            "nullable": true
          },
          "tenderHubUrl": {
            "type": "string",
            "description": "The category's page on the TenderHub website.",
            "nullable": true
          }
        },
        "additionalProperties": false,
        "description": "A TenderHub category in the reference list: the same slug, name and parentSlug as Category (the category of an\nopportunity or award), plus tenderHubUrl. A separate schema so the many Category objects inside feed items stay small."
      },
      "State": {
        "required": [
          "code",
          "name"
        ],
        "type": "object",
        "properties": {
          "code": {
            "type": "string",
            "description": "Stable lowercase code, for example nsw or nt. Use it as the state filter."
          },
          "name": {
            "type": "string",
            "description": "Display name, for example New South Wales."
          }
        },
        "additionalProperties": false,
        "description": "A state or territory."
      },
      "StateList": {
        "required": [
          "items"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/State"
            },
            "description": "The states, in code order."
          }
        },
        "additionalProperties": false,
        "description": "Every state and territory code."
      },
      "Status": {
        "required": [
          "code",
          "name"
        ],
        "type": "object",
        "properties": {
          "code": {
            "type": "string",
            "description": "Stable status code: open, newly_open, future_opportunity, closed, awarded, cancelled or archived. Match on this value; GET /api/integration/v1/reference/statuses lists them."
          },
          "name": {
            "type": "string",
            "description": "Display name of the status, for example Awarded. May change: match on code."
          }
        },
        "additionalProperties": false,
        "description": "The TenderHub status of an opportunity."
      },
      "StatusList": {
        "required": [
          "items"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Status"
            },
            "description": "The statuses, in name order."
          }
        },
        "additionalProperties": false,
        "description": "Every opportunity status."
      },
      "Supplier": {
        "required": [
          "awardCount",
          "id",
          "name",
          "slug"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "TenderHub supplier id, for example SUP-x9Yz12. Opaque: store it as a string."
          },
          "name": {
            "type": "string",
            "description": "Supplier (business) name."
          },
          "abn": {
            "type": "string",
            "description": "Australian Business Number, 11 digits. Null when not known.",
            "nullable": true
          },
          "website": {
            "type": "string",
            "description": "The supplier's website. Null when not known.",
            "nullable": true
          },
          "slug": {
            "type": "string",
            "description": "The supplier's slug on the TenderHub website. Can change: key on id, not on slug."
          },
          "awardCount": {
            "type": "integer",
            "description": "Number of distinct opportunities awarded to the supplier.",
            "format": "int32"
          },
          "totalAwardedValue": {
            "type": "number",
            "description": "Total value awarded to the supplier in AUD across those opportunities. Awards without a published value are left\nout of the total. Null when the source did not publish a value for any of them.",
            "format": "double",
            "nullable": true
          },
          "firstAwardedAt": {
            "type": "string",
            "description": "Date of the supplier's earliest recorded award (UTC).",
            "format": "date-time",
            "nullable": true
          },
          "lastAwardedAt": {
            "type": "string",
            "description": "Date of the supplier's latest recorded award (UTC).",
            "format": "date-time",
            "nullable": true
          },
          "tenderHubUrl": {
            "type": "string",
            "description": "Link to the supplier's page on the TenderHub website. Null when the supplier has no public page.",
            "nullable": true
          }
        },
        "additionalProperties": false,
        "description": "A supplier that has won government contracts, with totals across all of its recorded awards."
      },
      "SupplierAwardItem": {
        "required": [
          "categories",
          "locations",
          "opportunity"
        ],
        "type": "object",
        "properties": {
          "opportunity": {
            "$ref": "#/components/schemas/OpportunityRef"
          },
          "buyer": {
            "allOf": [
              {
                "$ref": "#/components/schemas/BuyerRef"
              }
            ],
            "description": "The buying organisation. Null when the source did not name one.",
            "nullable": true
          },
          "awardedAt": {
            "type": "string",
            "description": "When the award to this supplier was made (UTC). Null when not published.",
            "format": "date-time",
            "nullable": true
          },
          "value": {
            "type": "number",
            "description": "Value awarded to this supplier in AUD. When a source publishes one total for several suppliers it is split evenly\nbetween them. Null when the source did not publish a value.",
            "format": "double",
            "nullable": true
          },
          "totalValue": {
            "type": "number",
            "description": "Total awarded value of the opportunity in AUD, across all suppliers. Null when the source did not publish a value.",
            "format": "double",
            "nullable": true
          },
          "categories": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Category"
            },
            "description": "TenderHub categories of the opportunity (the most specific category per branch)."
          },
          "locations": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Location"
            },
            "description": "Locations the opportunity applies to."
          }
        },
        "additionalProperties": false,
        "description": "One opportunity awarded to the supplier."
      },
      "SupplierAwardsPage": {
        "required": [
          "hasMore",
          "items",
          "limit"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SupplierAwardItem"
            },
            "description": "Opportunities awarded to the supplier, newest award first. Awards without a published date come last."
          },
          "nextCursor": {
            "type": "string",
            "description": "Pass this as cursor (with the same from and to) to get the next page. Null when there are no more pages.",
            "nullable": true
          },
          "hasMore": {
            "type": "boolean",
            "description": "True when another page is available."
          },
          "limit": {
            "type": "integer",
            "description": "The page size that was applied.",
            "format": "int32"
          }
        },
        "additionalProperties": false,
        "description": "One page of a supplier's awards, newest first."
      },
      "SupplierChange": {
        "required": [
          "change",
          "changedAt",
          "id"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "TenderHub supplier id of the supplier that changed, for example SUP-x9Yz12. Opaque: store it as a string."
          },
          "change": {
            "type": "string",
            "description": "What changed, as of now:\nupdated (name, ABN, website or page changed: refresh your copy from supplier),\nunhidden (the supplier is visible again: refresh your copy from supplier),\nawards_changed (the supplier's set of awards changed: refetch GET /suppliers/{id} and its awards if you keep them;\nthe awards feed carries the award rows themselves),\nmerged (the supplier was merged into another one: to keep your copy accurate, repoint your references to\nmergedInto and drop the merged record; if mergedInto is null the merged-into supplier is not published, so handle\nit like hidden),\nhidden or deleted (the supplier is no longer published: to keep your copy accurate, drop it, and set supplier to\nnull on every award you hold whose supplier.id is this id, which is what the awards endpoints now return, because\nawards are not re-sent when a supplier is hidden; no supplier data is returned).\nNew codes may be added: treat an unknown code like updated."
          },
          "changedAt": {
            "type": "string",
            "description": "When TenderHub recorded the change (UTC).",
            "format": "date-time"
          },
          "mergedInto": {
            "type": "string",
            "description": "For merged only: the TenderHub supplier id of the supplier this one was merged into. Null for every other change,\nand null for merged when the successor is no longer published.",
            "nullable": true
          },
          "supplier": {
            "allOf": [
              {
                "$ref": "#/components/schemas/SupplierSummary"
              }
            ],
            "description": "The supplier's current record (name, ABN, website, page). Always null for hidden and deleted: a removed supplier's\ndetails are never returned. Also always null when your key does not hold suppliers:read (it reads this feed\nthrough awards:read or buyers:read): use id, change and mergedInto to keep the supplier names you hold in step.",
            "nullable": true
          }
        },
        "additionalProperties": false,
        "description": "A supplier that changed in a way that affects a copy you keep. One item per supplier: if a supplier changes twice\nbefore you poll, you see only its latest change. What to do with it depends on change."
      },
      "SupplierChangesPage": {
        "required": [
          "hasMore",
          "items",
          "limit",
          "nextCursor"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SupplierChange"
            },
            "description": "Suppliers that changed, in change order, one item per supplier (its latest change). A page may be short or\nempty while hasMore is true."
          },
          "nextCursor": {
            "type": "string",
            "description": "Pass this as cursor to get the next page. Always present: keep the last value and poll with it later to receive\nonly newer changes."
          },
          "hasMore": {
            "type": "boolean",
            "description": "True when more changes are available now. Keep following nextCursor while this is true."
          },
          "limit": {
            "type": "integer",
            "description": "The page size that was applied.",
            "format": "int32"
          }
        },
        "additionalProperties": false,
        "description": "One page of the supplier change feed, oldest change first."
      },
      "SupplierRef": {
        "required": [
          "id",
          "name",
          "slug"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "TenderHub supplier id, for example SUP-x9Yz12. Opaque and stable: store it as a string. Pass it to GET /api/integration/v1/suppliers/{supplierId}."
          },
          "name": {
            "type": "string",
            "description": "Supplier (business) name."
          },
          "slug": {
            "type": "string",
            "description": "The supplier's slug on the TenderHub website. Can change: key on id, not on slug."
          }
        },
        "additionalProperties": false,
        "description": "A supplier, as referenced from an award."
      },
      "SupplierSearchPage": {
        "required": [
          "hasMore",
          "items",
          "limit"
        ],
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SupplierSummary"
            },
            "description": "Matching suppliers, in name order."
          },
          "nextCursor": {
            "type": "string",
            "description": "Pass this as cursor (with the same abn, name or slug) to get the next page. Null when there are no more pages.",
            "nullable": true
          },
          "hasMore": {
            "type": "boolean",
            "description": "True when another page is available."
          },
          "limit": {
            "type": "integer",
            "description": "The page size that was applied.",
            "format": "int32"
          }
        },
        "additionalProperties": false,
        "description": "One page of supplier lookup results, in name order."
      },
      "SupplierSummary": {
        "required": [
          "id",
          "name",
          "slug"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "TenderHub supplier id, for example SUP-x9Yz12. Opaque and stable: store it as a string."
          },
          "name": {
            "type": "string",
            "description": "Supplier (business) name."
          },
          "abn": {
            "type": "string",
            "description": "Australian Business Number, 11 digits. Null when not known.",
            "nullable": true
          },
          "website": {
            "type": "string",
            "description": "The supplier's website. Null when not known.",
            "nullable": true
          },
          "slug": {
            "type": "string",
            "description": "The supplier's slug on the TenderHub website. Can change: key on id, not on slug."
          },
          "tenderHubUrl": {
            "type": "string",
            "description": "Link to the supplier's page on the TenderHub website. Null when the supplier has no public page.",
            "nullable": true
          }
        },
        "additionalProperties": false,
        "description": "A supplier as a lookup result (no award totals: use GET /api/integration/v1/suppliers/{supplierId} for those)."
      },
      "Usage": {
        "required": [
          "currentKey",
          "day",
          "keys",
          "organisation",
          "resetsAt"
        ],
        "type": "object",
        "properties": {
          "day": {
            "type": "string",
            "description": "The AEST calendar day the counts are for, as yyyy-MM-dd. The daily quota resets at midnight AEST (UTC+10)."
          },
          "resetsAt": {
            "type": "string",
            "description": "When the daily counts reset (the next midnight AEST, in UTC).",
            "format": "date-time"
          },
          "organisation": {
            "$ref": "#/components/schemas/UsageOrganisation"
          },
          "currentKey": {
            "$ref": "#/components/schemas/UsageCurrentKey"
          },
          "keys": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/UsageKey"
            },
            "description": "The organisation's keys that are active or were used today, oldest first."
          }
        },
        "additionalProperties": false,
        "description": "Today's requests (AEST day) for the organisation, the key making this request and every key of the organisation."
      },
      "UsageCurrentKey": {
        "required": [
          "displayPrefix",
          "minuteLimit",
          "minuteResetsAt",
          "usedThisMinute",
          "usedToday"
        ],
        "type": "object",
        "properties": {
          "displayPrefix": {
            "type": "string",
            "description": "The start of the key (thub_live_ plus 6 characters), as shown on the API access page. Not the secret."
          },
          "usedToday": {
            "type": "integer",
            "description": "Requests made today with this key, including this one.",
            "format": "int64"
          },
          "usedThisMinute": {
            "type": "integer",
            "description": "Requests made with this key in the current minute, including this one.",
            "format": "int64"
          },
          "minuteLimit": {
            "type": "integer",
            "description": "Requests allowed per key per minute.",
            "format": "int64"
          },
          "minuteResetsAt": {
            "type": "string",
            "description": "When the minute window resets (UTC).",
            "format": "date-time"
          }
        },
        "additionalProperties": false,
        "description": "The key making the request."
      },
      "UsageKey": {
        "required": [
          "displayPrefix",
          "name",
          "status",
          "usedToday"
        ],
        "type": "object",
        "properties": {
          "displayPrefix": {
            "type": "string",
            "description": "The start of the key (thub_live_ plus 6 characters), as shown on the API access page. Not the secret."
          },
          "name": {
            "type": "string",
            "description": "The name given to the key when it was created."
          },
          "status": {
            "type": "string",
            "description": "active, revoked or expired."
          },
          "usedToday": {
            "type": "integer",
            "description": "Requests made today with this key.",
            "format": "int64"
          }
        },
        "additionalProperties": false,
        "description": "One of the organisation's keys."
      },
      "UsageOrganisation": {
        "required": [
          "limit",
          "remaining",
          "used"
        ],
        "type": "object",
        "properties": {
          "used": {
            "type": "integer",
            "description": "Requests made today by all of the organisation's keys (including keys revoked during the day).",
            "format": "int64"
          },
          "limit": {
            "type": "integer",
            "description": "Requests allowed per organisation per AEST day.",
            "format": "int64"
          },
          "remaining": {
            "type": "integer",
            "description": "Requests left today (never below zero).",
            "format": "int64"
          }
        },
        "additionalProperties": false,
        "description": "The organisation's daily quota."
      },
      "ValueRange": {
        "type": "object",
        "properties": {
          "from": {
            "type": "number",
            "description": "Lower bound in AUD. Null when the source did not publish a value.",
            "format": "double",
            "nullable": true
          },
          "to": {
            "type": "number",
            "description": "Upper bound in AUD. Null when the source did not publish a value.",
            "format": "double",
            "nullable": true
          }
        },
        "additionalProperties": false,
        "description": "A value range in AUD. Either end may be null when the buyer published only one bound."
      }
    },
    "securitySchemes": {
      "ApiKey": {
        "type": "apiKey",
        "description": "Organisation API key (thub_live_...), created by an organisation admin on the TenderHub API access page.",
        "name": "X-Api-Key",
        "in": "header"
      }
    }
  },
  "security": [
    {
      "ApiKey": [ ]
    }
  ],
  "tags": [
    {
      "name": "Awards",
      "description": "Awarded contracts as a change feed."
    },
    {
      "name": "Buyers",
      "description": "Government buyers, their totals and the opportunities they awarded."
    },
    {
      "name": "Key",
      "description": "Check that an API key works and see the organisation, scopes and limits it carries."
    },
    {
      "name": "Opportunities",
      "description": "Opportunities (tenders, quote requests and so on) as a change feed, and one opportunity by reference."
    },
    {
      "name": "Reference",
      "description": "TenderHub's categories, locations, states, statuses and opportunity types: the values the other endpoints use."
    },
    {
      "name": "Suppliers",
      "description": "Supplier changes as a change feed."
    }
  ]
}
