# API Keys Source: https://docs.pinata.cloud/account-management/api-keys This page is where you can create, record, and delete API keys for the [Pinata API](/api-reference/introduction). Creating an API key is very simple! Just visit the page to start by click on the API Keys button in the left sidebar, then click "New Key" in the top right. In the New Key modal you can choose if you want the key to be an Admin key and have full access over every endpoint, or scope the keys by selecting which endpoints you want to use. You can also give it a limited number of uses, and be sure to give it a name to keep track of it. Once you have that filled out click "Create Key" and it will show you the `pinata_api_key`, `pinata_api_secret_key`, and the `JWT`. It's best to click "Copy All" and keep the API key data safe and secure. Once API keys have been created, you will not be able to see the secret or JWT again Once you have created your keys you can go ahead and try testing them! You can even use them in our [API Reference section](/api-reference/endpoint/ipfs/test-authentication) :eyes: Or feel free to paste this into your terminal with your `JWT` ```bash cURL curl --request GET \ --url https://api.pinata.cloud/data/testAuthentication \ --header 'accept: application/json' \ --header 'authorization: Bearer YOUR_PINATA_JWT' ``` If successful you should see this! ```shell bash { "message": "Congratulations! You are communicating with the Pinata API!" } ``` ## Managing Keys From the Keys Page you can see the name of a key, the public key, when it was issues, how many max uses it has, and what permissions it was given. At any point you can delete an API key by clicking on the Revoke button # Billing Source: https://docs.pinata.cloud/account-management/billing The billing page is where you can upgrade your account, view your current usage, or make changes to your billing info. ## Usage Heading over to the "Usage" tab, this is where you can view how much of your plan has been used in the month. Gateway Bandwidth and Requests are reset each month on your billing cycle date. If you reach 80% percent of your usage available, then you will start to receive emails and warnings that you are close to running out of space. If you are on the Free plan, then your account will no longer be able to upload or use the Dedicated Gateway once your account has gone above the limit by 25%. ## Payment Info Clicking the 'Manage Billing' button will show you the current card in use and if it's the default. If you want to remove a card, then you will need to add a new one first and set it as default before removing the old one. Pinata currently only accepts standard debit and credit cards ## Plan Selection From the plan selection you can choose a plan that fits your need the most, whether that be upgrading or downgrading. If you upgrade in the middle of a billing cycle, then you will only be charged the prorated amount # Limits Source: https://docs.pinata.cloud/account-management/limits The Private IPFS API and IPFS API have variying limits that users should be aware of. ## API Limits API rate limits on both the Private IPFS API and IPFS API are currently determined by plan type: | Plan | Rate Limit | | ------ | ----------------------- | | Free | 60 requests per minute | | Picnic | 250 requests per minute | | Fiesta | 500 requests per minute | ### Exceptions The following API calls have increased rate limits: * Endpoints under `api.pinata.cloud/data/` have a rate limit of 30 requests per minute * The [Pinning Services API endpoint for listing content](/api-reference/pinning-service-api) has a rate limit of 30 requests per minute ## File Restrictions HTML files can be uploaded on any plan, but can only be retrieved through a Dedicated Gateway with a [Custom Domain](gateways/dedicated-ipfs-gateways). Binary files are only allowed on a case by case basis, please contact [team@pinata.cloud](mailto:team@pinata.cloud) for assistance. ## Gateway Rate Limits At this time there are currently no rate limits for users retrieving content from a dedicated gateway. ## Upload Size Limits There differing limits on file sizes between the Private IPFS API and IPFS API ### Private IPFS API Files that are over **100MB** will require using [resumable uploads](/files/uploading-files#resumable-uploads) to complete. If you are using the SDK and the method `upload.file()` this will be handled automatically. Beyond 100MB the max file size is **25GB** at this time. ### IPFS API While the upload limit is 25GB we would recommend only uploading up to 15GB per file/folder for reliability reasons. We can try to assist uploads 15GB-25GB but we cannot guarantee success at this time. There is no aggregate limit for uploads, but each individual upload (whether it is a file or a folder) is limited to **25 GB**. There is also a file limit size of **10MB** for the pinJSONToIPFS API endpoint. # Webhooks Source: https://docs.pinata.cloud/account-management/webhooks Subscribe to Pinata API events using Webhooks Through the Pinata App you can create Webhooks for particular events fired from the Pinata API for your account specifically, like uploading or deleting a file. ## Setup Navigate to the [Webhooks Tab]() inside the Pinata App and click "Add Endpoint" in the top right. ![webhooks create](https://docs.mypinata.cloud/ipfs/bafkreig535s7dg4gokb37cl3khns7uaq5sqauyzdur2picd76xfzowd5m4) On the New Endpoint page you can put in a URL for your server endpoint that will receive the events. Additionally you can give it a description, which events it will subscribe to, and more advance options like rate limiting. Once you have your options selected click "Create" at the bottom. If you don't have an endpoint for your app or server yet, you can create a test one by clicking on the `Svix Play` link below the URL input. ![webhooks form](https://docs.mypinata.cloud/ipfs/bafkreicze5g4n2z7mr4r6o4p6o25lqbswsiytodqe6lwblzk2qmir6bpei) Once your Webhook is created you will be taken to the dashboard where you can see incoming logs and events that are fired. Try triggering one of the events that you've selected for your webhook either from the Pinata App or from the API. Then come back to the dashboard to see the result! ![webhooks dashboard](https://docs.mypinata.cloud/ipfs/bafybeicvtsffigooqn26s5zpgligxwjodlespt6a4lyfpzljn4h2ypu2jy) ## Event Catalog Check out the link below to browse all the available webhook events you can subscribe to! Visit our Svix page for all Pinata Webhook events! ## Signature Verification Webhook signatures let you verify that webhook messages are actually sent by Pinata and not a malicious actor. For a more detailed explanation, check out this article on [why you should verify webhooks](https://docs.svix.com/receiving/verifying-payloads/why). To grab the secret for your Webhook locate it on the Webhook Dashboard on the right sidebar. Click on the reveal icon to view the secret and copy it. ![webhook secret](https://docs.mypinata.cloud/ipfs/bafybeid6jzbykbdoo742rzyq2l6bswahdxbnl7fmdgcraanjeagtokoeb4) Our webhook partner Svix offers a set of useful libraries that make verifying webhooks very simple. Here is a an example using Javascript: ```typescript import { Webhook } from "svix"; const secret = "whsec_MfKQ9r8GKYqrTwjUPD8ILPZIo2LaLaSw"; // These were all sent from the server const headers = { "webhook-id": "msg_p5jXN8AQM9LWM0D4loKWxJek", "webhook-timestamp": "1614265330", "webhook-signature": "v1,g0hM9SsE+OTPJTGt/tmIKtSyZlE3uFJELVlNIOLJ1OE=", }; const payload = '{"test": 2432232314}'; const wh = new Webhook(secret); // Throws on error, returns the verified content on success const payload = wh.verify(payload, headers); ``` For more instructions and examples of how to verify signatures, check out their [webhook verification documentation](https://docs.svix.com/receiving/verifying-payloads/how). # Workspaces Source: https://docs.pinata.cloud/account-management/workspaces Workspaces is only available on the [Picnic and Fiesta plans](https://pinata.cloud/pricing) Workspaces is a feature that allows you to add multiple people to your account and collaborate in a natural way. With the Picnic plan, you'll get 3 seats to invite your teammates, and with Fiesta you'll get 5 seats, plus the ability to add more at an extra fee.