Getting Started
If you're new to the Tape API, you've come to the right place. In this guide you'll learn how to use the Tape API by interacting with a record.
Authentication
The easiest way to authenticate with the Developer API is to use your personal user API key. User API keys have the prefix user_key_
. If you are not already a Tape user, the first step is to sign up and create an account here.
Note that your API key carries the same privileges as your user account, so be sure to keep it secret! However, if your API key gets leaked, you can always deactivate it and generate a new one inside your user settings.
The Basics
The world runs on JSON over HTTP (or HTTPS hopefully). The Tape API is no exception, so if you know how to send and receive JSON data via HTTPS, you are all set.
The API is RESTful for the most part, meaning that you can use the HTTP verbs GET
, POST
, PUT
, and DELETE
to interact with resources like records, apps and workspaces.
The base URL to send all API requests is https://api.tapeapp.com
.
Retrieve your first Record
Records are the place where work gets done inside every Tape organization. The endpoint for retrieving a record is /v1/records/{record_id}
. Let's go ahead and retrieve a record:
- cURL
- Node.js
- PHP
- Python
curl https://api.tapeapp.com/v1/record/123 \
-u user_key_replace_with_your_api_key:
let req = https.get(
"https://api.tapeapp.com/v1/record/123",
{
method: "get",
headers: {
Authorization: "Bearer user_key_replace_with_your_api_key",
},
},
(res) => {
res.on("data", (data) => {
console.log(JSON.stringify(JSON.parse(data.toString()), null, 2));
});
}
);
<?php
$opts = array(
'http'=>array(
'method'=>"GET",
'header'=>"Authorization: Bearer user_key_replace_with_your_api_key"
)
);
$context = stream_context_create($opts);
$data = file_get_contents('https://api.tapeapp.com/v1/record/20', false, $context);
$responseContent = json_decode($data, true);
echo json_encode($responseContent, JSON_PRETTY_PRINT);
?>
import requests
import json
req = requests.get('https://api.tapeapp.com/v1/record/123', auth=('user_key_replace_with_your_api_key', ''))
print(json.dumps(req.json(), indent=2))
That's it, you just got your first response from the Tape API 🎉
Explore all you can do with records here.