POST
/
v2
/
contracts
/
getEditHistory
Get contract edit history
curl --request POST \
  --url https://api.metronome.com/v2/contracts/getEditHistory \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "customer_id": "13117714-3f05-48e5-a6e9-a66093f13b4d",
  "contract_id": "d7abd0cd-4ae9-4db7-8676-e986a4ebd8dc"
}'
{
  "data": [
    {
      "id": "d7abd0cd-4ae9-4db7-8676-e986a4ebd8dc",
      "add_commits": [
        {
          "id": "addda517-6d7a-42ea-834c-f5e6cf8c670e",
          "type": "PREPAID",
          "product": {
            "id": "2e30f074-d04c-412e-a134-851ebfa5ceb2",
            "name": "My product A"
          },
          "description": "A new commit",
          "applicable_product_tags": [
            "tag1",
            "tag2"
          ],
          "access_schedule": {
            "credit_type": {
              "id": "2714e483-4ff1-48e4-9e25-ac732e8f24f2",
              "name": "USD (cents)"
            },
            "schedule_items": [
              {
                "id": "2d45952c-5a6e-43a9-8aab-f61ee21be81a",
                "amount": 10000000,
                "starting_at": "2020-02-01T00:00:00.000Z",
                "ending_before": "2021-02-01T00:00:00.000Z"
              }
            ]
          },
          "invoice_schedule": {
            "credit_type": {
              "id": "2714e483-4ff1-48e4-9e25-ac732e8f24f2",
              "name": "USD (cents)"
            },
            "schedule_items": [
              {
                "id": "f15e4e23-f74e-4de4-9b3a-8b07434116c4",
                "invoice_id": "525b9759-7bbd-4a05-aab1-d7c43c976b57",
                "amount": 10000000,
                "unit_price": 10000000,
                "quantity": 1,
                "timestamp": "2020-03-01T00:00:00.000Z"
              }
            ],
            "do_not_invoice": false
          }
        }
      ]
    },
    {
      "id": "d7abd0cd-4ae9-4db7-8676-e986a4ebd8dc",
      "add_overrides": [
        {
          "id": "6cf3292a-e85c-4be6-822c-e25ba9d19757",
          "starting_at": "2020-01-01T00:00:00.000Z",
          "type": "MULTIPLIER",
          "multiplier": 1.5,
          "priority": 1,
          "override_specifiers": [
            {
              "product_tags": [
                "tag1"
              ],
              "pricing_group_values": {
                "region": "us-west-1",
                "hardware_type": "gpu"
              }
            }
          ],
          "entitled": true
        }
      ]
    }
  ]
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Contract ID

The body is of type object.

Response

Success

The response is of type object.