Accept or decline a project's price

How to either accept or decline a project price when you reach the price limit.

If the project is above the price limit, the project needs to be explicitly accepted or declined. The default price limit is 500 EUR. The price limit can be modified by updating the account billing details. 

  • Accept a price 

Endpoint 

https://api.platform.easytranslate.com/laas/api/v1/teams/:team_name/projects/:project_id/accept-price
 
In order to accept the price of a project, you need to send a POST request.
Make sure you are using the authorization token when you send the request. In the authorization section, select the type "Bearer Token".  You will then be asked to provide a value (= your access token) to the "token" key. 
In your request's header, you need to specify that json should be accepted. To do so, add "Accept" as a key and "application/json" as its value. 
Finally, you need to add variables to your endpoint path: 
    • Team_name: {{TEAM_NAME}} 
      Instead of {{TEAM_NAME}} , you need to provide the team_name of your team. It can be retrieved from the api/v1/user endpoint, as part of the account for which this project should be created. 
    • Project_id: {{PROJECT_ID}} 
      Instead of {{PROJECT_ID}} , you need to provide the ID of the project that needs to be accepted. 

Request example

curl --location -g --request POST 'https://api.platform.easytranslate.com/laas/api/v1/teams/{{TEAM_NAME}}/projects/{{PROJECT_ID}}/accept-price' \
--header 'Accept: application/json'
  • Decline a price 

Endpoint

https://api.platform.sandbox.easytranslate.com/api/v1/teams/:team_name/projects/:project_id/decline-price
 
In order to decline the price of a project, you need to send a POST request.
Make sure you are using the authorization token when you send the request. In the authorization section, select the type "Bearer Token".  You will then be asked to provide a value (= your access token) to the "token" key. 
In your request's header, you need to specify that json should be accepted. To do so, add "Accept" as a key and "application/json" as its value (It is not because you use the keyword "Accept" that you are accepting the price. You are accepting to decline the price). 
Finally, you need to add variables to your endpoint path: 
    • Team_name: {{TEAM_NAME}} 
      Instead of {{TEAM_NAME}} , you need to provide the team_name of your team. It can be retrieved from the api/v1/user endpoint, as part of the account for which this project should be created. 
    • Project_id: {{PROJECT_ID}} 
      Instead of {{PROJECT_ID}} , you need to provide the ID of the project that needs to be accepted. 

Request example 

curl --location -g --request POST 'https://api.platform.easytranslate.com/laas/api/v1/teams/{{TEAM_NAME}}/projects/{{PROJECT_ID}}/decline-price' \
--header 'Accept: application/json'