Skip to main content

How to View and Manage your GreaseBook API Keys

Getting data from Greasebook into your local system

Written by Marlee Rose

If your company uses the GreaseBook Public API, you can find your API key inside GreaseBook. You don’t need to wait for us to send it.

Who can do this: Only users with the Exec role. The API tab appears only if your company has Public API access. If you don’t see it, contact our support team.

Finding your Key

To find your key(s):

  1. Log in to GreaseBook.

  2. Go to Settings → Company.

  3. Open the API tab.

Or go there directly: https://app.greasebook.com/settings/company?tab=API
You’ll see the Public API Keys section, with your company’s key labelled primary.


For each key, you’ll see:

  • Name: the key’s label.

  • Key: the first characters of the key. The rest is hidden for security.

  • Access: Read only (can read data) or Read / write (can also send data to GreaseBook).

  • Created: the date the key was created.

Copying your Key

Click the Copy key icon to the right of the key. The full key is copied to your clipboard, ready to paste into your integration or give to your developer.
Keep your key private, like a password. Anyone who has it can reach your company’s data through the API.

Rotating a Key

If you think a key has been exposed or you want to change it as a precaution:

  1. Click the Rotate button next to the key.

  2. Confirm.

GreaseBook creates a new value for the key.

⚠ The old value stops working within 10 minutes, so update your integrations with the new value right away.


Deleting a Key

When you no longer need a key:

  1. Click the Delete button next to the key.

  2. Confirm.

⚠ Any integration using that key stops working within 10 minutes. This can’t be undone. If you delete your only key, you can create a new one with Create key.

Need More than One Key?

Your subscription includes one API key. Some companies need a separate key for each integration or vendor, so each one can be rotated or removed without affecting the others.
​

Additional API keys are not included in the base subscription, and extra fees may apply. To ask for more keys, contact our support team. Once approved, you’ll be able to create up to 4 keys from this same screen and choose read-only or read/write access for each one.

If your company’s API access is read-only, every key you create will also be read-only.

Using your Key

Send your key in the X-Api-Key header of each request. You’ll find the full Public API access information and documentation here: https://integration.greasebook.com/index.html

To retrieve your data, simply make a call to the API URL appending the termination for the information you need (found in the documentation above).
​
For example, you can get your daily Allocations by using the following method (HTTP Get)
​https://integration.greasebook.com/api/v1/wells/allocation?start=04/01/2020&end=05/22/2020&apiKey={YourCompanyKey}

where:

  • start refers to the initial date.

  • end to the ending date.

  • apiKey refers to the unique Key we provide to each operator.

You can see an example of how it works at the main URL below:

The data is sent to you in JSON format and it looks like this:

Finally, if you need any data that's not already outlined in the documentation INDEX or have additional questions, chat with us using the Messenger in the bottom-right corner of Greasebook.
​
In the meantime, safe operating and happy API'ing!! 🛢👾

Did this answer your question?