The US Marijuana Legalization API provides detailed information on cannabis laws across all 50 U.S. states, sourced from publicly available legislative data. It exposes granular, column-specific endpoints allowing users to query cannabis legality, decriminalization status, medical usage permissions, and overall policy summaries. Designed for developers, analysts, and advocacy groups, the API facilitates filtered queries to obtain insights into marijuana policies per state or across the nation. This modular and RESTful design prevents data overload and supports use cases like legal comparisons, trend analysis, and educational tools.
{"states":["Hawaii","Louisiana","Mississippi","Nebraska","New Hampshire","North Carolina","North Dakota","Alabama","Arkansas","Florida","Idaho","Kansas","Oklahoma","Pennsylvania","South Carolina","South Dakota","Utah","West Virginia","Wyoming","Alaska","Arizona","California","Colorado","Connecticut","Delaware","District of Columbia","Illinois","Maine","Maryland","Massachusetts","Michigan","Minnesota","Missouri","Montana","Nevada","New Jersey","New Mexico","New York","Ohio","Oregon","Rhode Island","Vermont","Virginia","Washington","Georgia","Indiana","Iowa","Kentucky","Tennessee","Texas","Wisconsin"]}
curl --location --request POST 'https://zylalabs.com/api/7056/us+marijuana+legalization+api/10956/get+states+in+the+us' --header 'Authorization: Bearer YOUR_API_KEY' --header 'Content-Type: application/json' --data-raw '{}'
{"state":"Wisconsin","recreational_use":"Illegal"}
curl --location --request POST 'https://zylalabs.com/api/7056/us+marijuana+legalization+api/10957/check+recreational+cannabis+legality+by+state' --header 'Authorization: Bearer YOUR_API_KEY' --header 'Content-Type: application/json' --data-raw '{"state":"Required"}'
{"state":"New York","medicinal_use":"Legal"}
curl --location --request POST 'https://zylalabs.com/api/7056/us+marijuana+legalization+api/10958/check+medicinal+cannabis+legality' --header 'Authorization: Bearer YOUR_API_KEY' --header 'Content-Type: application/json' --data-raw '{"state":"Required"}'
| Header | Description |
|---|---|
Authorization
|
[Required] Should be Bearer access_key. See "Your API Access Key" above when you are subscribed. |
No long-term commitment. Upgrade, downgrade, or cancel anytime. Free Trial includes up to 50 requests.
Each endpoint returns JSON-formatted data. The "get states" endpoint provides a list of U.S. states, while the "check recreational" and "check medicinal" endpoints return the legality status of cannabis use in a specified state.
The key fields include "states" in the first endpoint, and "state," "recreational_use," or "medicinal_use" in the legality endpoints. These fields indicate the state and the corresponding legality status of cannabis.
The "get states" endpoint lists all U.S. states, while the legality endpoints provide information on whether recreational or medicinal cannabis use is legal in a specified state.
The response data is organized in a structured JSON format. For example, the legality endpoints return a state name along with its corresponding legality status, making it easy to parse and utilize in applications.
The data is sourced from publicly available legislative information, ensuring that it reflects current cannabis laws across all 50 U.S. states.
Typical use cases include legal comparisons between states, trend analysis of cannabis legislation, and educational tools for advocacy groups or researchers interested in cannabis policy.
Users can customize requests by specifying the state parameter in the legality endpoints. This allows them to retrieve specific information about cannabis legality for any state of interest.
Users can utilize the returned data by integrating it into applications for legal research, policy analysis, or educational resources, leveraging the structured format for easy data manipulation and visualization.
To obtain your API key, you first need to sign in to your account and subscribe to the API you want to use. Once subscribed, go to your Profile, open the Subscription section, and select the specific API. Your API key will be available there and can be used to authenticate your requests.
You can’t switch APIs during the free trial. If you subscribe to a different API, your trial will end and the new subscription will start as a paid plan.
If you don’t cancel before the 7th day, your free trial will end automatically and your subscription will switch to a paid plan under the same plan you originally subscribed to, meaning you will be charged and gain access to the API calls included in that plan.
The free trial ends when you reach 50 API requests or after 7 days, whichever comes first.
No, the free trial is available only once, so we recommend using it on the API that interests you the most. Most of our APIs offer a free trial, but some may not include this option.
Yes, we offer a 7-day free trial that allows you to make up to 50 API calls at no cost, so you can test our APIs without any commitment.
Zyla API Hub is like a big store for APIs, where you can find thousands of them all in one place. We also offer dedicated support and real-time monitoring of all APIs. Once you sign up, you can pick and choose which APIs you want to use. Just remember, each API needs its own subscription. But if you subscribe to multiple ones, you'll use the same key for all of them, making things easier for you.
Service Level:
100%
Response Time:
1,384ms
Service Level:
100%
Response Time:
53ms
Service Level:
100%
Response Time:
6,613ms
Service Level:
100%
Response Time:
67ms
Service Level:
100%
Response Time:
5,655ms
Service Level:
100%
Response Time:
1,439ms
Service Level:
100%
Response Time:
5,617ms
Service Level:
100%
Response Time:
53ms
Service Level:
100%
Response Time:
79ms
Service Level:
100%
Response Time:
55ms
Service Level:
100%
Response Time:
3,111ms
Service Level:
100%
Response Time:
2,583ms
Service Level:
100%
Response Time:
3,328ms
Service Level:
100%
Response Time:
2,904ms
Service Level:
100%
Response Time:
2,366ms
Service Level:
100%
Response Time:
2,975ms
Service Level:
100%
Response Time:
2,500ms
Service Level:
100%
Response Time:
3,506ms
Service Level:
100%
Response Time:
2,426ms
Service Level:
100%
Response Time:
2,724ms