API Documentation

API Endpoint

Rate cards

Rate cards

Supported filter params

  • company_id (array)
GET /api/v2/rate_cards
Requestsreturns rate cards

GET  /api/v2/rate_cards

Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Responses200
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
  "data": [
    {
      "id": "15",
      "type": "rate_cards",
      "attributes": {
        "name": "Rate card",
        "created_at": "2025-08-01T06:07:07.597+02:00",
        "updated_at": "2025-08-01T06:07:07.597+02:00",
        "archived_at": null,
        "prices_count": 0
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": "1061"
          }
        },
        "company": {
          "meta": {
            "included": false
          }
        },
        "creator": {
          "meta": {
            "included": false
          }
        }
      }
    }
  ],
  "links": {
    "first": "http://api-test.productive.io/api/v2/rate_cards?page%5Bnumber%5D=1&page%5Bsize%5D=30",
    "last": "http://api-test.productive.io/api/v2/rate_cards?page%5Bnumber%5D=1&page%5Bsize%5D=30"
  },
  "meta": {
    "current_page": 1,
    "total_pages": 1,
    "total_count": 1,
    "page_size": 30,
    "max_page_size": 200
  }
}

Get rate cards
GET/api/v2/rate_cards


GET /api/v2/rate_cards/1
Requestsreturns price

GET  /api/v2/rate_cards/16

Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Responses200
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
  "data": {
    "id": "16",
    "type": "rate_cards",
    "attributes": {
      "name": "Rate card",
      "created_at": "2025-08-01T06:07:07.654+02:00",
      "updated_at": "2025-08-01T06:07:07.654+02:00",
      "archived_at": null,
      "prices_count": 0
    },
    "relationships": {
      "organization": {
        "data": {
          "type": "organizations",
          "id": "1062"
        }
      },
      "company": {
        "meta": {
          "included": false
        }
      },
      "creator": {
        "meta": {
          "included": false
        }
      }
    }
  },
  "meta": {}
}

Gets a rate card
GET/api/v2/rate_cards/{id}

URI Parameters
HideShow
id
number (required) Example: 1

rate card id


POST /api/v2/rate_cards
Requestscreates pricereturns error

POST  /api/v2/rate_cards

Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
  "data": {
    "type": "rate cards",
    "attributes": {
      "name": "test name"
    },
    "relationships": {
      "company": {
        "data": {
          "type": "companies",
          "id": "2851"
        }
      }
    }
  }
}
Responses201
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
  "data": {
    "id": "18",
    "type": "rate_cards",
    "attributes": {
      "name": "test name",
      "created_at": "2025-08-01T06:07:07.716+02:00",
      "updated_at": "2025-08-01T06:07:07.716+02:00",
      "archived_at": null,
      "prices_count": 0
    },
    "relationships": {
      "organization": {
        "data": {
          "type": "organizations",
          "id": "1063"
        }
      },
      "company": {
        "meta": {
          "included": false
        }
      },
      "creator": {
        "meta": {
          "included": false
        }
      }
    }
  },
  "meta": {}
}

POST  /api/v2/rate_cards

Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
  "data": {
    "type": "rate cards",
    "attributes": {
      "name": ""
    }
  }
}
Responses422
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
  "errors": [
    {
      "status": "422",
      "code": "invalid_attribute",
      "title": "Invalid Attribute",
      "detail": "can't be blank",
      "source": {
        "pointer": "data/attributes/name"
      }
    },
    {
      "status": "422",
      "code": "invalid_attribute",
      "title": "Invalid Attribute",
      "detail": "can't be blank",
      "source": {
        "pointer": "data/attributes/company"
      }
    }
  ]
}

Create a price
POST/api/v2/rate_cards

URI Parameters
HideShow
name
string (required) Example: Name

name

company_id
number (required) Example: 1

company id


PATCH /api/v2/rate_cards/1
Requestsupdates rate cardreturns errorreturns error

PATCH  /api/v2/rate_cards/20

Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
  "data": {
    "type": "rate cards",
    "attributes": {
      "name": "new name"
    }
  }
}
Responses200
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
  "data": {
    "id": "20",
    "type": "rate_cards",
    "attributes": {
      "name": "new name",
      "created_at": "2025-08-01T06:07:07.824+02:00",
      "updated_at": "2025-08-01T06:07:07.833+02:00",
      "archived_at": null,
      "prices_count": 0
    },
    "relationships": {
      "organization": {
        "data": {
          "type": "organizations",
          "id": "1065"
        }
      },
      "company": {
        "meta": {
          "included": false
        }
      },
      "creator": {
        "meta": {
          "included": false
        }
      }
    }
  },
  "meta": {}
}

PATCH  /api/v2/rate_cards/21

Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
  "data": {
    "type": "rate cards",
    "attributes": {
      "name": ""
    },
    "relationships": {
      "company": {
        "data": {
          "type": "companies",
          "id": "0"
        }
      }
    }
  }
}
Responses422
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
  "errors": [
    {
      "status": "422",
      "code": "invalid_attribute",
      "title": "Invalid Attribute",
      "detail": "can't be blank",
      "source": {
        "pointer": "data/attributes/name"
      }
    }
  ]
}

PATCH  /api/v2/rate_cards/22

Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
  "data": {
    "type": "prices",
    "attributes": {
      "name": ""
    }
  }
}
Responses422
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
  "errors": [
    {
      "status": "422",
      "code": "invalid_attribute",
      "title": "Invalid Attribute",
      "detail": "can't be blank",
      "source": {
        "pointer": "data/attributes/name"
      }
    }
  ]
}

Update a price
PATCH/api/v2/rate_cards/{id}

URI Parameters
HideShow
id
number (required) Example: 1

rate card id


POST /api/v2/rate_cards/copy
Requestscopy from templatereturns errorreturns error

POST  /api/v2/rate_cards/copy

Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
  "data": {
    "type": "deals",
    "attributes": {
      "name": "TESTING",
      "template_id": 24,
      "price_ids": [
        18
      ]
    }
  }
}
Responses201
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
  "data": {
    "id": "25",
    "type": "rate_cards",
    "attributes": {
      "name": "TESTING",
      "created_at": "2025-08-01T06:07:08.009+02:00",
      "updated_at": "2025-08-01T06:07:08.012+02:00",
      "archived_at": null,
      "prices_count": 1
    },
    "relationships": {
      "organization": {
        "data": {
          "type": "organizations",
          "id": "1068"
        }
      },
      "company": {
        "meta": {
          "included": false
        }
      },
      "creator": {
        "meta": {
          "included": false
        }
      }
    }
  },
  "meta": {}
}

POST  /api/v2/rate_cards/copy

Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
  "data": {
    "type": "rate_cards",
    "attributes": {}
  }
}
Responses422
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
  "errors": [
    {
      "status": "422",
      "code": "invalid_attribute",
      "title": "Invalid Attribute",
      "detail": "can't be blank",
      "source": {
        "pointer": "data/attributes/template_id"
      }
    }
  ]
}

POST  /api/v2/rate_cards/copy

Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Body
{
  "data": {
    "type": "rate_cards",
    "attributes": {
      "name": "copied rate card",
      "template_id": 0
    }
  }
}
Responses404
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
  "errors": [
    {
      "status": "404",
      "code": "record_not_found",
      "title": "Record Not Found",
      "detail": "The requested record was not found",
      "source": {}
    }
  ]
}

Copy a rate card
POST/api/v2/rate_cards/copy

URI Parameters
HideShow
name
string (optional) Example: Name

name

template_id
number (required) Example: 1

template id

price_ids
array (optional) Example: %5B1%2C+2%5D

rate ids to copy


DELETE /api/v2/rate_cards/1
Requestsarchives rate card

DELETE  /api/v2/rate_cards/28

Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Responses204
This response has no content.

Deletes a price
DELETE/api/v2/rate_cards/{id}

URI Parameters
HideShow
id
number (required) Example: 1

rate card id


PATCH /api/v2/rate_cards/1/archive
Requestsarchives rate card

PATCH  /api/v2/rate_cards/29/archive

Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Responses200
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
  "data": {
    "id": "29",
    "type": "rate_cards",
    "attributes": {
      "name": "Rate card",
      "created_at": "2025-08-01T06:07:08.244+02:00",
      "updated_at": "2025-08-01T06:07:08.253+02:00",
      "archived_at": "2025-08-01T06:07:08.000+02:00",
      "prices_count": 0
    },
    "relationships": {
      "organization": {
        "data": {
          "type": "organizations",
          "id": "1072"
        }
      },
      "company": {
        "meta": {
          "included": false
        }
      },
      "creator": {
        "meta": {
          "included": false
        }
      }
    }
  },
  "meta": {}
}

Archives a rate card
PATCH/api/v2/rate_cards/{id}/archive

URI Parameters
HideShow
id
number (required) Example: 1

rate card id


PATCH /api/v2/rate_cards/1/restore
Requestsrestores rate card

PATCH  /api/v2/rate_cards/30/restore

Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+json
Responses200
Headers
Content-Type: application/vnd.api+json; charset=utf-8
Body
{
  "data": {
    "id": "30",
    "type": "rate_cards",
    "attributes": {
      "name": "Rate card",
      "created_at": "2025-08-01T06:07:08.300+02:00",
      "updated_at": "2025-08-01T06:07:08.309+02:00",
      "archived_at": null,
      "prices_count": 0
    },
    "relationships": {
      "organization": {
        "data": {
          "type": "organizations",
          "id": "1073"
        }
      },
      "company": {
        "meta": {
          "included": false
        }
      },
      "creator": {
        "meta": {
          "included": false
        }
      }
    }
  },
  "meta": {}
}

Restores a rate card
PATCH/api/v2/rate_cards/{id}/restore

URI Parameters
HideShow
id
number (required) Example: 1

rate card id


Generated by aglio on 01 Aug 2025