---
title: Get pet's prescriptions
slug: import-test-pdf/get-pets-prescriptions
createdAt: 2025-10-28T16:28:34.269Z
---

{
  "id": "zbd4l2QRZBmKA5MSeXVc7",
  "type": "api-oas-v2",
  "data": {
    "method": "GET",
    "url": "/api/v1/pets/{id}/prescriptions",
    "servers": [],
    "name": "Get pet's prescriptions",
    "description": "Get pet's prescriptions",
    "contentType": "application/json",
    "request": {
      "pathParameters": [],
      "headerParameters": [],
      "queryParameters": [
        {
          "kind": "required",
          "name": "filter[status]",
          "type": "string",
          "description": "Prescription's Status"
        }
      ],
      "bodyDataParameters": [],
      "formDataParameters": [],
      "oAuthParameters": []
    },
    "responses": [
      {
        "statusCode": "200",
        "description": "successful operation",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "description": "",
            "schema": [
              {
                "name": "data",
                "kind": "optional",
                "type": "array",
                "description": "",
                "modelRef": "#/components/schemas/Prescription",
                "customType": "Prescription[]",
                "schema": [
                  {
                    "name": "id",
                    "kind": "optional",
                    "type": "integer",
                    "description": "",
                    "example": 1
                  },
                  {
                    "name": "record_id",
                    "kind": "optional",
                    "type": "integer",
                    "description": "",
                    "example": 1
                  },
                  {
                    "name": "clinic_id",
                    "kind": "optional",
                    "type": "integer",
                    "description": "",
                    "example": 1
                  },
                  {
                    "name": "vet_id",
                    "kind": "optional",
                    "type": "integer",
                    "description": "",
                    "example": 1
                  },
                  {
                    "name": "pet_id",
                    "kind": "optional",
                    "type": "integer",
                    "description": "",
                    "example": 1
                  },
                  {
                    "name": "product_id",
                    "kind": "optional",
                    "type": "integer",
                    "description": "",
                    "example": 1
                  },
                  {
                    "name": "product_name",
                    "kind": "optional",
                    "type": "string",
                    "description": "",
                    "example": "Product name"
                  },
                  {
                    "name": "type",
                    "kind": "optional",
                    "type": "integer",
                    "description": "`0` - External `1` - In House\n",
                    "example": 0
                  },
                  {
                    "name": "quantity",
                    "kind": "optional",
                    "type": "integer",
                    "description": "",
                    "example": 1
                  },
                  {
                    "name": "unit_id",
                    "kind": "optional",
                    "type": "integer",
                    "description": "",
                    "example": 1
                  },
                  {
                    "name": "unit",
                    "kind": "optional",
                    "type": "string",
                    "description": "",
                    "example": "Unit"
                  },
                  {
                    "name": "label",
                    "kind": "optional",
                    "type": "string",
                    "description": "",
                    "example": "Administer 1 tablet by mouth every 12 hours for 7 days"
                  },
                  {
                    "name": "prescribed_at",
                    "kind": "optional",
                    "type": "string<date-time>",
                    "description": "",
                    "example": "2020-01-01T00:00:00Z"
                  },
                  {
                    "name": "expires_at",
                    "kind": "optional",
                    "type": "string<date-time>",
                    "description": "",
                    "example": "2020-01-01T00:00:00Z"
                  },
                  {
                    "name": "status",
                    "kind": "optional",
                    "type": "string<ACTIVE | INACTIVE>",
                    "description": "",
                    "example": "ACTIVE"
                  },
                  {
                    "name": "internal_notes",
                    "kind": "optional",
                    "type": "string",
                    "description": "",
                    "example": "Internal notes"
                  },
                  {
                    "name": "refills_received",
                    "kind": "optional",
                    "type": "integer",
                    "description": "",
                    "example": 1
                  },
                  {
                    "name": "max_refills",
                    "kind": "optional",
                    "type": "integer",
                    "description": "",
                    "example": 3
                  },
                  {
                    "name": "last_refill_at",
                    "kind": "optional",
                    "type": "string<date-time>",
                    "description": "",
                    "example": "2020-01-01T00:00:00Z"
                  },
                  {
                    "name": "refills",
                    "kind": "optional",
                    "type": "array",
                    "description": "",
                    "modelRef": "#/components/schemas/Refill",
                    "customType": "Refill[]",
                    "schema": [
                      {
                        "name": "id",
                        "kind": "optional",
                        "type": "integer",
                        "description": "",
                        "example": 1
                      },
                      {
                        "name": "prescription_id",
                        "kind": "optional",
                        "type": "integer",
                        "description": "",
                        "example": 1
                      },
                      {
                        "name": "record_id",
                        "kind": "optional",
                        "type": "integer",
                        "description": "",
                        "example": 1
                      },
                      {
                        "name": "vet_id",
                        "kind": "optional",
                        "type": "integer",
                        "description": "",
                        "example": 1
                      },
                      {
                        "name": "type",
                        "kind": "optional",
                        "type": "integer",
                        "description": "`0` - External `1` - In House\n",
                        "example": 0
                      },
                      {
                        "name": "label",
                        "kind": "optional",
                        "type": "string",
                        "description": "",
                        "example": "Refill"
                      },
                      {
                        "name": "refilled_at",
                        "kind": "optional",
                        "type": "string<date-time>",
                        "description": "",
                        "example": "2020-01-01T00:00:00.000Z"
                      },
                      {
                        "name": "is_initial",
                        "kind": "optional",
                        "type": "boolean",
                        "description": "",
                        "example": false
                      },
                      {
                        "name": "number",
                        "kind": "optional",
                        "type": "integer",
                        "description": "",
                        "example": 1
                      },
                      {
                        "name": "internal_notes",
                        "kind": "optional",
                        "type": "string",
                        "description": "",
                        "example": "Internal Notes"
                      }
                    ]
                  },
                  {
                    "name": "created_at",
                    "kind": "optional",
                    "type": "string<date-time>",
                    "description": "",
                    "example": "2022-02-06T22:00:00.000000Z"
                  },
                  {
                    "name": "updated_at",
                    "kind": "optional",
                    "type": "string<date-time>",
                    "description": "",
                    "example": "2022-02-06T22:00:00.000000Z"
                  }
                ]
              },
              {
                "name": "links",
                "kind": "optional",
                "type": "object",
                "description": "",
                "modelRef": "#/paths/~1api~1v1~1pets/get/responses/200/content/application~1json/schema/properties/links",
                "customType": "links",
                "schema": []
              },
              {
                "name": "meta",
                "kind": "optional",
                "type": "object",
                "description": "",
                "modelRef": "#/paths/~1api~1v1~1pets/get/responses/200/content/application~1json/schema/properties/meta",
                "customType": "meta",
                "schema": []
              }
            ],
            "isExpanded": true
          }
        ]
      }
    ],
    "hasXCodeSamples": false,
    "examples": {
      "languages": [
        {
          "id": "example-0-curl",
          "language": "curl",
          "label": "cURL",
          "code": "curl --request GET \\\n     --url '/api/v1/pets/{id}/prescriptions?filter[status]=string' \\\n     --header 'accept: application/json'"
        },
        {
          "id": "example-1-javascript",
          "language": "javascript",
          "label": "javascript",
          "code": "var myHeaders = new Headers();\nmyHeaders.append(\"accept\", \"application/json\");\nmyHeaders.append(\"content-type\", \"application/json\");\n\nvar requestOptions = {\n   method: 'GET',\n   headers: myHeaders,\n   redirect: 'follow'\n};\n\nfetch(\"/api/v1/pets/{id}/prescriptions?filter[status]=string\", requestOptions)\n   .then(response => response.text())\n   .then(result => console.log(result))\n   .catch(error => console.log('error', error));"
        },
        {
          "id": "example-2-ruby",
          "language": "ruby",
          "label": "Ruby",
          "code": "require \"uri\"\nrequire \"json\"\nrequire \"net/http\"\n\nurl = URI(\"/api/v1/pets/{id}/prescriptions?filter[status]=string\")\n\nhttp = Net::HTTP.new(url.host, url.port);\nrequest = Net::HTTP::Get.new(url)\nrequest[\"accept\"] = \"application/json\"\nrequest[\"content-type\"] = \"application/json\"\n\nresponse = http.request(request)\nputs response.read_body\n"
        },
        {
          "id": "example-3-python",
          "language": "python",
          "label": "Python",
          "code": "import requests\nimport json\n\nurl = \"/api/v1/pets/{id}/prescriptions?filter[status]=string\"\n\npayload = {}\nheaders = {\n   'accept': 'application/json',\n   'content-type': 'application/json'\n}\n\nresponse = requests.request(\"GET\", url, headers=headers, data=payload)\n\nprint(response.text)\n"
        }
      ],
      "selectedLanguageId": "example-0-curl"
    },
    "results": {
      "languages": [
        {
          "id": "response-0-200",
          "language": "200",
          "code": "// successful operation\n{\n  \"data\": [\n    {\n      \"id\": 1,\n      \"record_id\": 1,\n      \"clinic_id\": 1,\n      \"vet_id\": 1,\n      \"pet_id\": 1,\n      \"product_id\": 1,\n      \"product_name\": \"Product name\",\n      \"type\": 0,\n      \"quantity\": 1,\n      \"unit_id\": 1,\n      \"unit\": \"Unit\",\n      \"label\": \"Administer 1 tablet by mouth every 12 hours for 7 days\",\n      \"prescribed_at\": \"2020-01-01T00:00:00Z\",\n      \"expires_at\": \"2020-01-01T00:00:00Z\",\n      \"status\": \"ACTIVE\",\n      \"internal_notes\": \"Internal notes\",\n      \"refills_received\": 1,\n      \"max_refills\": 3,\n      \"last_refill_at\": \"2020-01-01T00:00:00Z\",\n      \"refills\": [\n        {\n          \"id\": 1,\n          \"prescription_id\": 1,\n          \"record_id\": 1,\n          \"vet_id\": 1,\n          \"type\": 0,\n          \"label\": \"Refill\",\n          \"refilled_at\": \"2020-01-01T00:00:00.000Z\",\n          \"is_initial\": false,\n          \"number\": 1,\n          \"internal_notes\": \"Internal Notes\"\n        }\n      ],\n      \"created_at\": \"2022-02-06T22:00:00.000000Z\",\n      \"updated_at\": \"2022-02-06T22:00:00.000000Z\"\n    }\n  ],\n  \"links\": {},\n  \"meta\": {}\n}"
        }
      ],
      "selectedLanguageId": "response-0-200"
    }
  },
  "children": [
    {
      "text": ""
    }
  ]
}