{"openapi":"3.1.0","info":{"title":"POST /api/v1/contracts/{contract_id}/pause","version":"1.0.0","description":"Pause contract"},"servers":[{"url":"https://api.ondayzero.com","description":"Production"}],"paths":{"/api/v1/contracts/{contract_id}/pause":{"post":{"tags":["contracts"],"summary":"Pause contract","description":"Pause an active contract.","operationId":"pause_contract_api_v1_contracts__contract_id__pause_post","parameters":[{"name":"contract_id","in":"path","required":true,"schema":{"type":"string","title":"Contract Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}},{"name":"x-business-id","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Business-Id"}}],"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SuccessEnvelope_ContractResponse_"}}}},"400":{"description":"Bad Request - Invalid input","content":{"application/json":{"example":{"detail":"Invalid request parameters"}}}},"401":{"description":"Unauthorized - Authentication required","content":{"application/json":{"example":{"detail":"Not authenticated"}}}},"403":{"description":"Forbidden - Insufficient permissions","content":{"application/json":{"example":{"detail":"Not enough permissions"}}}},"404":{"description":"Not Found - Resource does not exist","content":{"application/json":{"example":{"detail":"Resource not found"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"ContractResponse":{"properties":{"id":{"type":"string","title":"Id"},"business_id":{"type":"string","title":"Business Id"},"order_id":{"type":"string","title":"Order Id"},"project_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Id"},"customer_id":{"type":"string","title":"Customer Id"},"customer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Customer Name"},"number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Number"},"status":{"type":"string","title":"Status"},"currency":{"type":"string","title":"Currency"},"original_value_cents":{"type":"integer","title":"Original Value Cents","default":0},"current_value_cents":{"type":"integer","title":"Current Value Cents","default":0},"billed_cents":{"type":"integer","title":"Billed Cents","default":0},"recognized_cents":{"type":"integer","title":"Recognized Cents","default":0},"deferred_remaining_cents":{"type":"integer","title":"Deferred Remaining Cents","default":0},"billed_pct":{"type":"number","title":"Billed Pct","default":0.0},"earned_pct":{"type":"number","title":"Earned Pct","default":0.0},"total_contracted_hours":{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$","title":"Total Contracted Hours","default":"0"},"hours_drawn":{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$","title":"Hours Drawn","default":"0"},"hours_remaining":{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$","title":"Hours Remaining","default":"0"},"first_invoice_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"First Invoice Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"can_be_paused":{"type":"boolean","title":"Can Be Paused","default":false},"can_be_resumed":{"type":"boolean","title":"Can Be Resumed","default":false},"can_be_amended":{"type":"boolean","title":"Can Be Amended","default":false}},"type":"object","required":["id","business_id","order_id","customer_id","status","currency","created_at","updated_at"],"title":"ContractResponse","description":"Response schema for a contract."},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"SuccessEnvelope_ContractResponse_":{"properties":{"success":{"type":"boolean","title":"Success","default":true},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message"},"code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Code"},"data":{"anyOf":[{"$ref":"#/components/schemas/ContractResponse"},{"type":"null"}]}},"additionalProperties":true,"type":"object","title":"SuccessEnvelope[ContractResponse]"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}},"securitySchemes":{"BearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"API Token","description":"API token authentication. Format: `Bearer dz_...`"}}},"security":[{"BearerAuth":[]}]}