Suppliers prices

Suppliers prices represent default prices that is applied to all jobs created whatever the supplier. These prices can be overridden at the supplier level.

The supplier price object

Properties

  • idstring

    Unique identifier for the object.

  • clientobject

    The client.
  • currencyobject

    The currency.
  • domainobject

    The domain of expertise.
  • languagePairobject

    The language pair.
  • matchesarray

    The matches.
  • matchesTypestring

    How the matches are calculated. Valid values are fixed or percentage.

  • quantityTypeobject

    The quantity type.
  • serviceobject

    The service.
  • unitCostnumber

    The cost per unit.

supplier price object

{
  "id": "6548c1965136b418fd626e83",
  "service": {
     "id": "6548c16d5136b418fd626e5f", 
     "name": "Translation" 
  },
  "quantityType": {
    "id": "6548c16d5136b418fd626e61", 
    "name": "Words" 
  },
  "currency": { 
    "code": "EUR", 
    "symbol": "€" 
  },
  "unitCost": 0.16,
  "matchesType": "fixed",
  "matches": [
    {
      "percentage": 1,
      "unitCost": 0.16,
      "id": "655c61aa0ecf6202a9edb710",
      "name": "0%"
    },
    {
      "percentage": 1,
      "unitCost": 0.08,
      "id": "655c61a70ecf6202a9edb70e",
      "name": "100%"
    },
    {
      "percentage": 1,
      "unitCost": 0.12,
      "id": "655c61af0ecf6202a9edb712",
      "name": "Fuzzies"
    }
  ]
}

GET/v2/account/prices/suppliers/

List all suppliers prices

This endpoint allows you to retrieve all the suppliers prices. This endpoint is paginated.

Request

GET
/v2/account/prices/suppliers/
curl -G https://api.lsp.expert/v2/account/prices/suppliers/ \
  -u {key}: 

Response

{
  "items": [
    {
      "id": "6548c1965136b418fd626e83",
      "service": {
        "id": "6548c16d5136b418fd626e5f", 
        "name": "Translation" 
      },
      "quantityType": {
        "id": "6548c16d5136b418fd626e61", 
        "name": "Words" 
      },
      "currency": { 
        "code": "EUR", 
        "symbol": "€" 
      },
      "unitCost": 0.16,
      "matchesType": "fixed",
      "matches": [
        {
          "percentage": 1,
          "unitCost": 0.16,
          "id": "655c61aa0ecf6202a9edb710",
          "name": "0%"
        },
        {
          "percentage": 1,
          "unitCost": 0.08,
          "id": "655c61a70ecf6202a9edb70e",
          "name": "100%"
        },
        {
          "percentage": 1,
          "unitCost": 0.12,
          "id": "655c61af0ecf6202a9edb712",
          "name": "Fuzzies"
        }
      ]
    }
    // ...
  ],
  "pageSize": 20,
  "page": 1,
  "totalPages": 1,
  "totalItems": 2,
  "hasNextPage": false,
  "hasPreviousPage": false
}


POST/v2/account/prices/suppliers/

Create a supplier price

This endpoint allows you to add a new supplier price.

Parameters

  • clientstring

    The client id.

  • currencystring Required

    The currency code (ISO, e.g., EUR).

  • domainstring

    The domain of expertise id.

  • languagePairstring

    The language pair id.

  • matchesTypestring Required

    How the matches are calculated. Valid values are fixed or percentage.

  • quantityTypestring Required

    The quantity type id.

  • servicestring Required

    The service id.

  • unitCostnumber Required

    The cost per unit.

Request

POST
/v2/account/prices/suppliers/
curl https://api.lsp.expert/v2/account/prices/suppliers/ \
  -u {key}: \
  -d currency="EUR" \
  -d quantityType="6548c16d5136b418fd626e61" \
  -d service="6548c16d5136b418fd626e5f"
  -d languagePair="659bf8f35959fed584cd38e1"
  -d unitCost=0.16
  -d matchesType="fixed"

Response

{
  "id": "66e7f69da9d8b6741f4a441d",
  "languagePair": {
    "id": "659bf8f35959fed584cd38e1",
    "source": { 
      "code": "en", 
      "name": "English" 
    },
    "target": { 
      "code": "fr", 
      "name": "French" 
    },
    "bidirectional": false
  },
  "currency": { 
    "code": "EUR", 
    "symbol": "€" 
  },
  "unitCost": 0.16,
  "matchesType": "fixed",
  "service": { 
    "id": "6548c16d5136b418fd626e5f", 
    "name": "Translation" 
  },
  "quantityType": { 
    "id": "6548c16d5136b418fd626e61", 
    "name": "Words" 
  },
  "matches": []
}

GET/v2/account/prices/suppliers/:id

Retrieve a supplier price

This endpoint allows you to retrieve a supplier price by providing their id.

Request

GET
/v2/account/prices/suppliers/:id
curl https://api.lsp.expert/v2/account/prices/suppliers/66e7f69da9d8b6741f4a441d \
  -u {key}:

Response

{
  "id": "66e7f69da9d8b6741f4a441d",
  "languagePair": {
    "id": "659bf8f35959fed584cd38e1",
    "source": { 
      "code": "en", 
      "name": "English" 
    },
    "target": { 
      "code": "fr", 
      "name": "French" 
    },
    "bidirectional": false
  },
  "currency": { 
    "code": "EUR", 
    "symbol": "€" 
  },
  "unitCost": 0.16,
  "matchesType": "fixed",
  "service": { 
    "id": "6548c16d5136b418fd626e5f", 
    "name": "Translation" 
  },
  "quantityType": { 
    "id": "6548c16d5136b418fd626e61", 
    "name": "Words" 
  },
  "matches": []
}


PUT/v2/account/prices/suppliers/:id

Update a supplier price

This endpoint allows you to perform an update on a supplier price. Any parameters not provided will be left unchanged.

Parameters

  • matchesTypestring

    How the matches are calculated. Valid values are fixed or percentage.

  • unitCostnumber Required

    The cost per unit.

Request

PUT
/v2/account/prices/suppliers/:id
curl -X PUT https://api.lsp.expert/v2/account/prices/suppliers/66e7f69da9d8b6741f4a441d \
  -u {key}: \
  -d unitCost="0.18"

Response

{
  "id": "66e7f69da9d8b6741f4a441d",
  "languagePair": {
    "id": "659bf8f35959fed584cd38e1",
    "source": { 
      "code": "en", 
      "name": "English" 
    },
    "target": { 
      "code": "fr", 
      "name": "French" 
    },
    "bidirectional": false
  },
  "currency": { 
    "code": "EUR", 
    "symbol": "€" 
  },
  "unitCost": 0.18,
  "matchesType": "fixed",
  "service": { 
    "id": "6548c16d5136b418fd626e5f", 
    "name": "Translation" 
  },
  "quantityType": { 
    "id": "6548c16d5136b418fd626e61", 
    "name": "Words" 
  },
  "matches": []
}

DELETE/v2/account/prices/suppliers/:id

Delete a supplier price

This endpoint allows you to delete a supplier price.

Request

DELETE
/v2/account/prices/suppliers/:id
curl -X DELETE https://api.lsp.expert/v2/account/prices/suppliers/66e7f69da9d8b6741f4a441d \
  -u {key}:

POST/v2/account/prices/suppliers/:id/matches

Add a match for a supplier price

This endpoint allows you to add a match category on a supplier price.

Parameters

  • matchstring Required

    The match id.

  • percentagenumber

    The percentage of the price unit cost. (If matchesType is percentage)

  • unitCostnumber

    The cost per unit. (If matchesType is fixed)

Request

POST
/v2/account/prices/suppliers/:id/matches
curl https://api.lsp.expert/v2/account/prices/suppliers/66e7f69da9d8b6741f4a441d/match \
  -u {key}: \
  -d match="655c61aa0ecf6202a9edb710" \
  -d unitCost=0.16

Response

{
  "id": "66e830a5a9d8b6741f4a4423",
  "service": { 
    "id": "6548c16d5136b418fd626e5f", 
    "name": "Translation" 
  },
  "languagePair": {
    "source": { 
      "code": "en", 
      "name": "English" 
    },
    "target": { 
      "code": "fr", 
      "name": "French" 
    },
    "id": "659bf8f35959fed584cd38e1",
    "bidirectional": false
  },
  "quantityType": { 
    "id": "6548c16d5136b418fd626e61", 
    "name": "Words" 
  },
  "currency": { 
    "code": "EUR", 
    "symbol": "€" 
  },
  "unitCost": 0.18,
  "matchesType": "fixed",
  "matches": [
    {
      "percentage": 1,
      "unitCost": 0.16,
      "id": "655c61aa0ecf6202a9edb710",
      "name": "0%"
    }
  ]  
}

PUT/v2/account/prices/suppliers/:id/matches/:matchId

Update a match for a supplier price

This endpoint allows you to update a match category on a supplier price.

Parameters

  • percentagenumber

    percentage

  • unitCostnumber

    The cost per unit.

Request

PUT
/v2/account/prices/suppliers/:id/matches/:matchId
curl https://api.lsp.expert/v2/account/prices/suppliers/66e7f69da9d8b6741f4a441d/match/655c61aa0ecf6202a9edb710 \
  -u {key}: \
  -d unitCost=0.18

Response

{
  "id": "66e830a5a9d8b6741f4a4423",
  "service": { 
    "id": "6548c16d5136b418fd626e5f", 
    "name": "Translation" 
  },
  "languagePair": {
    "source": { 
      "code": "en", 
      "name": "English" 
    },
    "target": { 
      "code": "fr", 
      "name": "French" 
    },
    "id": "659bf8f35959fed584cd38e1",
    "bidirectional": false
  },
  "quantityType": { 
    "id": "6548c16d5136b418fd626e61", 
    "name": "Words" 
  },
  "currency": { 
    "code": "EUR", 
    "symbol": "€" 
  },
  "unitCost": 0.18,
  "matchesType": "fixed",
  "matches": [
    {
      "percentage": 1,
      "unitCost": 0.18,
      "id": "655c61aa0ecf6202a9edb710",
      "name": "0%"
    }
  ]  
}

PUT/v2/account/prices/suppliers/:id/matches/:matchId/move/:newPosition

Move a match for a supplier price

This endpoint allows you to modify a match category order. Note that this order is used when adding a price.

Request

PUT
/v2/account/prices/suppliers/:id/matches/:matchId/move/:newPosition
curl https://api.lsp.expert/v2/account/prices/suppliers/66e7f69da9d8b6741f4a441d/matches/655c61aa0ecf6202a9edb710/move/1 \
  -u {key}: \

Response

{
  "id": "66e830a5a9d8b6741f4a4423",
  "service": { 
    "id": "6548c16d5136b418fd626e5f", 
    "name": "Translation" 
  },
  "languagePair": {
    "source": { 
      "code": "en", 
      "name": "English" 
    },
    "target": { 
      "code": "fr", 
      "name": "French" 
    },
    "id": "659bf8f35959fed584cd38e1",
    "bidirectional": false
  },
  "quantityType": { 
    "id": "6548c16d5136b418fd626e61", 
    "name": "Words" 
  },
  "currency": { 
    "code": "EUR", 
    "symbol": "€" 
  },
  "unitCost": 0.18,
  "matchesType": "fixed",
  "matches": [
    {
      "percentage": 1,
      "unitCost": 0.18,
      "id": "655c61aa0ecf6202a9edb710",
      "name": "0%"
    }
  ]  
}



DEL/v2/account/prices/suppliers/:id/matches/:matchId

Remove a match for a supplier price

This endpoint allows you to remove a match category on a supplier price.

Request

DEL
/v2/account/prices/suppliers/:id/matches/:matchId
curl https://api.lsp.expert/v2/account/prices/suppliers/66e7f69da9d8b6741f4a441d/matches/655c61aa0ecf6202a9edb710 \
  -u {key}: 

Response

{
  "id": "66e830a5a9d8b6741f4a4423",
  "service": { 
    "id": "6548c16d5136b418fd626e5f", 
    "name": "Translation" 
  },
  "languagePair": {
    "source": { 
      "code": "en", 
      "name": "English" 
    },
    "target": { 
      "code": "fr", 
      "name": "French" 
    },
    "id": "659bf8f35959fed584cd38e1",
    "bidirectional": false
  },
  "quantityType": { 
    "id": "6548c16d5136b418fd626e61", 
    "name": "Words" 
  },
  "currency": { 
    "code": "EUR", 
    "symbol": "€" 
  },
  "unitCost": 0.18,
  "matchesType": "fixed",
  "matches": []  
}


GET/v2/account/prices/suppliers/

Search suppliers prices

Search a price using query languages.

Available query parameters for search

  • client.id[]string

    The client id(s).

  • service.id[]string

    The service id(s).

  • quantityType.id[]string

    The quantity type id(s).

  • domain.id[]string

    The domain id(s).

  • languagePair.id[]string

    The language pair id(s).

  • currency[]string

    The currency code(s).

Request

GET
/v2/account/prices/suppliers/
curl -G https://api.lsp.expert/v2/account/prices/suppliers/ \
  -u {key}: \
  -d "service.id[]=6548c16d5136b418fd626e5f"