Skip to main content
POST
/
api
/
goodrx
/
classes
/goodrx/classes
curl --request POST \
  --url https://api.anysite.io/api/goodrx/classes \
  --header 'Content-Type: application/json' \
  --header 'access-token: <api-key>' \
  --data '
{
  "drug_class": "<string>",
  "timeout": 300
}
'
[
  {
    "@type": "@goodrx_drug_class",
    "id": "<string>",
    "slug": "<string>",
    "name": "<string>",
    "description": "<string>",
    "drugs": []
  }
]

Authorizations

access-token
string
header
required

API token from the dashboard

Headers

access-token
string
required

Body

application/json
drug_class
string
required

Drug class slug or a GoodRx class URL

Minimum string length: 1
Examples:

"statins"

"https://www.goodrx.com/classes/statins"

timeout
integer
default:300

Max scrapping execution timeout (in seconds)

Required range: 20 <= x <= 1500

Response

Successful Response

@type
string
default:@goodrx_drug_class
id
string | null
slug
string | null
name
string | null
description
string | null
drugs
GoodrxClassDrug · object[]