> For the complete documentation index, see [llms.txt](https://dev.ropo.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://dev.ropo.com/api-reference/contract.md).

# Contract

Job contracts

## PATCH /contract

> Update a contract

```json
{"openapi":"3.1.0","info":{"title":"Ropo One","version":"1.0.0"},"tags":[{"name":"contract","description":"Job contracts"}],"servers":[{"url":"/rest","description":"Ropo One"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"type":"http","bearerFormat":"JWT","scheme":"bearer"}},"schemas":{"ContractUpdateRequest":{"title":"ContractUpdateRequest","description":"ContractUpdateRequest","properties":{"data":{"$ref":"#/components/schemas/JobContract"}},"type":"object"},"JobContract":{"title":"JobContract","description":"JobContract","required":["contract_no"],"properties":{"contract_no":{"description":"Contract number","type":"string"},"name":{"type":["string","null"]},"startdate":{"type":["string","null"]},"enddate":{"description":"Contract end date","type":["string","null"]},"contractstatus":{"description":"Status of contract (active, closed, terminated)","type":["string","null"]},"type":{"description":"Type of contract (insurance)","type":["string","null"]},"termination_date":{"description":"Contract termination date","type":["string","null"]},"terminationterm":{"description":"Contract termination term. Number of days termination will be done.","type":["integer","null"]},"product":{"description":"Contract product name","type":["string","null"]}},"type":"object"},"HttpApiProblem":{"title":"HttpApiProblem","description":"HttpApiProblem","properties":{"status":{"description":"The HTTP status code generated by the origin server for this occurrence of the problem","type":["integer","null"]},"type":{"description":"A URI reference that identifies the problem type","type":["string","null"]},"title":{"description":"A short, human-readable summary of the problem type","type":["string","null"]},"detail":{"description":"A human-readable explanation specific to this occurrence of the problem","type":["string","null"]}},"type":"object"}}},"paths":{"/contract":{"patch":{"tags":["contract"],"summary":"Update a contract","operationId":"updateContractAction","requestBody":{"description":"JSON data with contract details.","required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ContractUpdateRequest"}}}},"responses":{"200":{"description":"Returns success message if contract was succesfully updated.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ContractUpdateRequest"}}}},"400":{"description":"Bad request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HttpApiProblem"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HttpApiProblem"}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HttpApiProblem"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HttpApiProblem"}}}}}}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://dev.ropo.com/api-reference/contract.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
