{"openapi":"3.1.0","info":{"title":"Tendar API","version":"1.0.0"},"paths":{"/api/v1/workspaces":{"get":{"operationId":"list_workspaces","summary":"List workspaces","tags":["Workspaces"],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"workspaces:read","security":[{"bearer":[]}]}},"/api/v1/profiles":{"get":{"operationId":"list_profiles","summary":"List saved tender views","tags":["Profiles"],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"tenders:read","security":[{"bearer":[]}]},"post":{"operationId":"create_profile","summary":"Save a tender view","tags":["Profiles"],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"definition":{"type":"object","properties":{"version":{"type":"number","const":2},"filter":{"anyOf":[{"$ref":"#/$defs/__schema0"},{"type":"null"}]},"search":{"type":"string","maxLength":200},"sort":{"maxItems":5,"type":"array","items":{"type":"object","properties":{"field":{"type":"string","minLength":1,"maxLength":64},"dir":{"type":"string","enum":["asc","desc"]}},"required":["field","dir"]}},"columns":{"maxItems":30,"type":"array","items":{"type":"string","minLength":1,"maxLength":64}},"groups":{"maxItems":3,"type":"array","items":{"type":"object","properties":{"field":{"type":"string","minLength":1,"maxLength":64},"order":{"type":"object","properties":{"by":{"type":"string","minLength":1,"maxLength":64},"dir":{"type":"string","enum":["asc","desc"]}},"required":["by","dir"]}},"required":["field","order"]}},"display":{"type":"string","minLength":1,"maxLength":64},"show_empty_groups":{"type":"boolean"},"hidden_groups":{"type":"object","propertyNames":{"type":"string","minLength":1,"maxLength":64},"additionalProperties":{"type":"object","propertyNames":{"type":"string","maxLength":300},"additionalProperties":{"type":"boolean"}}},"date_field":{"type":"string","minLength":1,"maxLength":64},"end_date_field":{"type":"string","minLength":1,"maxLength":64},"value_field":{"anyOf":[{"type":"string","minLength":1,"maxLength":64},{"type":"null"}]},"time_scale":{"type":"string","enum":["week","month","quarter","year"]},"calendar_month":{"type":"string","pattern":"^\\d{4}-(0[1-9]|1[0-2])$"},"toggles":{"type":"object","propertyNames":{"type":"string","minLength":1,"maxLength":64},"additionalProperties":{"type":"boolean"}}},"required":["version","filter","search","sort","columns","groups","display"]},"visibility":{"default":"workspace","type":"string","enum":["private","workspace","public"]}},"required":["name","definition"],"$defs":{"__schema0":{"anyOf":[{"type":"object","properties":{"field":{"type":"string","minLength":1,"maxLength":64},"op":{"type":"string","enum":["eq","neq","in","contains","before","after","gte","lte","is_empty"]},"value":{"anyOf":[{"type":"string","maxLength":300},{"maxItems":50,"type":"array","items":{"type":"string","maxLength":300}},{"type":"null"}]}},"required":["field","op","value"]},{"type":"object","properties":{"op":{"type":"string","enum":["and","or","not"]},"children":{"minItems":1,"maxItems":50,"type":"array","items":{"$ref":"#/$defs/__schema0"}}},"required":["op","children"]}]}}}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"profiles:write","security":[{"bearer":[]}]}},"/api/v1/favorites":{"get":{"operationId":"list_favorite_tenders","summary":"List your favourite tenders in the workspace","tags":["Favorites"],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"tenders:read","security":[{"bearer":[]}]},"post":{"operationId":"set_tender_favorite","summary":"Mark or unmark a tender as favourite","tags":["Favorites"],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"tender_id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"favorite":{"type":"boolean"}},"required":["tender_id","favorite"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"favorites:write","security":[{"bearer":[]}]}},"/api/v1/profile-favorites":{"get":{"operationId":"list_favorite_profiles","summary":"List your favourite profiles in the workspace","tags":["Favorites"],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"tenders:read","security":[{"bearer":[]}]},"post":{"operationId":"set_profile_favorite","summary":"Mark or unmark a profile as favourite","tags":["Favorites"],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"profile_id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"favorite":{"type":"boolean"}},"required":["profile_id","favorite"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"favorites:write","security":[{"bearer":[]}]}},"/api/v1/alerts":{"get":{"operationId":"list_alerts","summary":"List workspace alerts","tags":["Alerts"],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"alerts:read","security":[{"bearer":[]}]},"post":{"operationId":"create_alert","summary":"Create an alert from a profile or filter","tags":["Alerts"],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"profile_id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"filters":{"type":"object","properties":{"q":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"contracting_party":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"cpv":{"default":[],"maxItems":50,"type":"array","items":{"type":"string","pattern":"^\\d{2,8}$"}},"sources":{"default":[],"maxItems":10,"type":"array","items":{"type":"string","minLength":1}},"min_relevance":{"anyOf":[{"type":"number","minimum":0,"maximum":1},{"type":"null"}]},"budget_min":{"anyOf":[{"type":"number","minimum":0},{"type":"null"}]},"budget_max":{"anyOf":[{"type":"number","minimum":0},{"type":"null"}]}},"additionalProperties":false},"definition":{"type":"object","properties":{"version":{"type":"number","const":2},"filter":{"anyOf":[{"$ref":"#/$defs/__schema0"},{"type":"null"}]},"search":{"type":"string","maxLength":200},"sort":{"maxItems":5,"type":"array","items":{"type":"object","properties":{"field":{"type":"string","minLength":1,"maxLength":64},"dir":{"type":"string","enum":["asc","desc"]}},"required":["field","dir"]}},"columns":{"maxItems":30,"type":"array","items":{"type":"string","minLength":1,"maxLength":64}},"groups":{"maxItems":3,"type":"array","items":{"type":"object","properties":{"field":{"type":"string","minLength":1,"maxLength":64},"order":{"type":"object","properties":{"by":{"type":"string","minLength":1,"maxLength":64},"dir":{"type":"string","enum":["asc","desc"]}},"required":["by","dir"]}},"required":["field","order"]}},"display":{"type":"string","minLength":1,"maxLength":64},"show_empty_groups":{"type":"boolean"},"hidden_groups":{"type":"object","propertyNames":{"type":"string","minLength":1,"maxLength":64},"additionalProperties":{"type":"object","propertyNames":{"type":"string","maxLength":300},"additionalProperties":{"type":"boolean"}}},"date_field":{"type":"string","minLength":1,"maxLength":64},"end_date_field":{"type":"string","minLength":1,"maxLength":64},"value_field":{"anyOf":[{"type":"string","minLength":1,"maxLength":64},{"type":"null"}]},"time_scale":{"type":"string","enum":["week","month","quarter","year"]},"calendar_month":{"type":"string","pattern":"^\\d{4}-(0[1-9]|1[0-2])$"},"toggles":{"type":"object","propertyNames":{"type":"string","minLength":1,"maxLength":64},"additionalProperties":{"type":"boolean"}}},"required":["version","filter","search","sort","columns","groups","display"]},"notify_new":{"default":true,"type":"boolean"},"deadline_days":{"default":null,"anyOf":[{"type":"integer","minimum":1,"maximum":60},{"type":"null"}]},"notify_email":{"default":true,"type":"boolean"},"cooldown_minutes":{"default":60,"type":"integer","minimum":0,"maximum":10080}},"required":["name"],"$defs":{"__schema0":{"anyOf":[{"type":"object","properties":{"field":{"type":"string","minLength":1,"maxLength":64},"op":{"type":"string","enum":["eq","neq","in","contains","before","after","gte","lte","is_empty"]},"value":{"anyOf":[{"type":"string","maxLength":300},{"maxItems":50,"type":"array","items":{"type":"string","maxLength":300}},{"type":"null"}]}},"required":["field","op","value"]},{"type":"object","properties":{"op":{"type":"string","enum":["and","or","not"]},"children":{"minItems":1,"maxItems":50,"type":"array","items":{"$ref":"#/$defs/__schema0"}}},"required":["op","children"]}]}}}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"alerts:write","security":[{"bearer":[]}]}},"/api/v1/alerts/{id}":{"patch":{"operationId":"update_alert","summary":"Update an alert","tags":["Alerts"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"notify_new":{"type":"boolean"},"deadline_days":{"anyOf":[{"type":"integer","minimum":1,"maximum":60},{"type":"null"}]},"notify_email":{"type":"boolean"},"cooldown_minutes":{"type":"integer","minimum":0,"maximum":10080},"is_active":{"type":"boolean"}},"required":[],"additionalProperties":false}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"alerts:write","security":[{"bearer":[]}]},"delete":{"operationId":"remove_alert","summary":"Remove an alert","tags":["Alerts"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"alerts:write","security":[{"bearer":[]}]}},"/api/v1/bid-packs":{"get":{"operationId":"list_bid_packs","summary":"List specialty packs","tags":["Bids"],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"bids:read","security":[{"bearer":[]}]}},"/api/v1/tenders/{tender_id}":{"get":{"operationId":"get_tender","summary":"Read a tender in the selected workspace","tags":["Tenders"],"parameters":[{"name":"tender_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"tenders:read","security":[{"bearer":[]}]}},"/api/v1/tenders/search":{"post":{"operationId":"search_tenders","summary":"Search visible tenders","tags":["Tenders"],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"filter":{"anyOf":[{"anyOf":[{"type":"string"},{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}]},{"type":"null"}]},"sort":{"type":"string"},"limit":{"default":50,"type":"integer","minimum":1,"maximum":500},"offset":{"default":0,"type":"integer","minimum":0,"maximum":100000}},"required":[]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"tenders:read","security":[{"bearer":[]}]}},"/api/v1/tenders/match":{"post":{"operationId":"match_tenders","summary":"Match visible tenders","tags":["Tenders"],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"filter":{"anyOf":[{"anyOf":[{"type":"string"},{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}]},{"type":"null"}]},"sort":{"type":"string"},"limit":{"default":50,"type":"integer","minimum":1,"maximum":500},"offset":{"default":0,"type":"integer","minimum":0,"maximum":100000},"first_seen_after":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"},{"type":"null"}]},"deadline_within_days":{"anyOf":[{"type":"integer","minimum":1,"maximum":60},{"type":"null"}]}},"required":[]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"tenders:read","security":[{"bearer":[]}]}},"/api/v1/bid-packs/{key}":{"get":{"operationId":"get_bid_pack","summary":"Read a specialty pack","tags":["Bids"],"parameters":[{"name":"key","in":"path","required":true,"schema":{"type":"string","pattern":"^[a-z][a-z0-9-]*$"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"bids:read","security":[{"bearer":[]}]},"patch":{"operationId":"update_bid_pack","summary":"Publish a new workspace pack revision","tags":["Bids"],"parameters":[{"name":"key","in":"path","required":true,"schema":{"type":"string","pattern":"^[a-z][a-z0-9-]*$"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"pack_yaml":{"type":"string","minLength":1}},"required":["pack_yaml"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"bids:write","security":[{"bearer":[]}]}},"/api/v1/bids":{"get":{"operationId":"list_bids","summary":"List workspace bids","tags":["Bids"],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"bids:read","security":[{"bearer":[]}]},"post":{"operationId":"create_bid","summary":"Create a specialty bid","tags":["Bids"],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"tender_id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"pack_key":{"type":"string","pattern":"^[a-z][a-z0-9-]*$"}},"required":["tender_id","pack_key"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"bids:write","security":[{"bearer":[]}]}},"/api/v1/bids/{id}":{"get":{"operationId":"get_bid","summary":"Read a bid and its evidence","tags":["Bids"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"bids:read","security":[{"bearer":[]}]}},"/api/v1/bids/{id}/jobs":{"post":{"operationId":"start_bid_agent","summary":"Queue a specialty draft agent","tags":["Bids"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"budget_usd":{"default":2,"type":"number","exclusiveMinimum":0,"maximum":20}},"required":[]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"bids:write","security":[{"bearer":[]}]}},"/api/v1/bids/{id}/draft":{"post":{"operationId":"accept_bid_draft","summary":"Validate and accept a cited YAML draft","tags":["Bids"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"draft_yaml":{"type":"string","minLength":1}},"required":["draft_yaml"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"bids:write","security":[{"bearer":[]}]}},"/api/v1/bids/{id}/rules/{rule_id}":{"patch":{"operationId":"update_bid_rule","summary":"Update a quantity rule with a review reason","tags":["Bids"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"rule_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"quantity":{"type":"number","minimum":0},"reason":{"type":"string","minLength":1}},"required":["quantity","reason"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"bids:write","security":[{"bearer":[]}]}},"/api/v1/bids/{id}/quantities/measured":{"post":{"operationId":"record_bid_measurement","summary":"Record a measured quantity with evidence","tags":["Bids"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"location_id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"item_code":{"type":"string","minLength":1},"quantity":{"type":"number","minimum":0},"evidence":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}},"required":["location_id","item_code","quantity","evidence"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"bids:write","security":[{"bearer":[]}]}},"/api/v1/bids/{id}/quantities":{"post":{"operationId":"calculate_bid_quantities","summary":"Calculate quantities from reviewed locations and rules","tags":["Bids"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"bids:write","security":[{"bearer":[]}]}},"/api/v1/bids/{id}/generate":{"post":{"operationId":"generate_bid_deliverables","summary":"Generate bid deliverables","tags":["Bids"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"bids:write","security":[{"bearer":[]}]}},"/api/v1/bids/{id}/state":{"patch":{"operationId":"update_bid_state","summary":"Advance a bid review state","tags":["Bids"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"state":{"type":"string","enum":["running","review","approved","failed"]}},"required":["state"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"bids:write","security":[{"bearer":[]}]}},"/api/v1/bids/{id}/deliverables/{deliverable_id}/state":{"patch":{"operationId":"update_bid_deliverable_state","summary":"Advance a deliverable review state","tags":["Bids"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"deliverable_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"state":{"type":"string","enum":["reviewed","approved","draft"]}},"required":["state"]}}}},"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"bids:write","security":[{"bearer":[]}]}},"/api/v1/tenders/vocabulary":{"get":{"operationId":"tender_vocabulary","summary":"Tender Vocabulary","tags":["tenders"],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Missing or invalid credential"},"403":{"description":"The credential lacks the required scope"},"422":{"description":"Invalid input"},"429":{"description":"Rate limited"}},"x-required-scope":"tenders:read","security":[{"bearer":[]}]}}},"servers":[{"url":"https://tendar.io"}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","description":"Workspace API key or OAuth access token"}}}}