Direct API Usage
Access the Bkper REST API directly from any language using Bearer token authentication. Covers the OpenAPI and Google Discovery specifications, getting a token via CLI or OAuth, optional API keys for dedicated quota, and the interactive API explorer.
The Bkper REST API is the universal interface for interacting with Bkper Books. Every library and tool — bkper-js, bkper-gs, the CLI — is built on top of it. You can use it directly from any language or platform.
Base URL
https://api.bkper.appAll API calls use this endpoint:
https://api.bkper.app/v5/books— List bookshttps://api.bkper.app/v5/books/{bookId}— Get a specific book
Specifications
The API is built on OpenAPI and Google API Discovery specifications:
You can use these specifications to generate client libraries with tools like OpenAPI generator or Google APIs code generator in the language of your choice.
For TypeScript, we maintain an updated type definitions package:
Getting started
To use the API, you need a valid OAuth2 access token. No API key is required — the Bkper API proxy provides a managed key with shared quota.
CLI / Node.js
Use bkper-js with the CLI for authentication:
import { Bkper } from 'bkper-js';import { getOAuthToken } from 'bkper';
Bkper.setConfig({ oauthTokenProvider: async () => getOAuthToken(),});
const bkper = new Bkper();const books = await bkper.getBooks();First authenticate via CLI: bkper auth login
Web applications
Use bkper-js with @bkper/web-auth for browser authentication:
import { Bkper } from 'bkper-js';import { BkperAuth } from '@bkper/web-auth';
const auth = new BkperAuth({ onLoginSuccess: () => initApp() });await auth.init();
Bkper.setConfig({ oauthTokenProvider: async () => auth.getAccessToken(),});
const bkper = new Bkper();const books = await bkper.getBooks();Google Apps Script
Use bkper-gs:
function listBooks() { var books = BkperApp.getBooks(); books.forEach(function (book) { Logger.log(book.getName()); });}Direct HTTP calls
For any language, send a Bearer token in the Authorization header:
Authorization: Bearer YOUR_ACCESS_TOKENFor details on obtaining tokens, see Authentication.
API Explorer
The REST API Explorer lets you browse endpoints, inspect payload formats, and try the API live:
Custom API key
For dedicated quota and project-level usage tracking, you can optionally configure your own API key:
- Join bkper@googlegroups.com to unlock access to enable the API on your project
- Create a new GCP project, or select an existing one
- Enable the Bkper API in the Google Cloud Console
- Create an API key
- Add API Restrictions to
app.bkper.comAPI only
- Add API Restrictions to
Send your API key in the bkper-api-key HTTP header:
bkper-api-key: YOUR_API_KEYMetrics
With your own API key, you can view detailed metrics on the GCP Console for your project’s API calls:
The metrics dashboard provides information about endpoint calls, latency, and errors — a good overview of your integration’s health.
Quota
The quotas dashboard provides details of the current default and quota exceeded errors.
The default shared quota is 60 requests per minute. If you need higher limits with your own API key, please get in touch so we can discuss your case.