Request
Base URL
https://api.bookfunnel.com/v1
Arguments
All arguments are passed as simple POST parameters in the request.
Response
All responses are formatted as JSON and have application/json as the Content-Type.
HTTP Status Codes
BookFunnel uses these HTTP response codes:
HTTP Code | Description |
---|---|
200 | OK |
400 | Bad Request |
410 | Invalid API Key |
500 | Internal Server Error |
Response With Error
Every error has the structure described below.
{ "status": "ERR", "message": "Error message" "code": Error Code }
Authenticating
Send your BookFunnel API key in the X-BookFunnel-APIKey header. To obtain an API key, contact support@bookfunnel.com.
Reference
Sending Books
/v1/create_book_link
Create a unique link against a book on BookFunnel and return that unique link. This is useful for sending your own emails from your system. BookFunnel will generate the link against the book, but no email will be sent.
PARAMS
Parameter | Description |
---|---|
object | The book ID of the book to generate a link for, in the form of BFXXXXXXXXXX. This can be found at the bottom of the book details view for each book. (required) |
The reader’s email address (required) |
Response
{ "status": "OK", "message": "Link created.", "link": Reader's download link, "code": Reader's download code }
/v1/create_link
Create a unique link against an opt-in landing page on BookFunnel and return that unique link. This is useful for sending your own emails from your system. BookFunnel will generate the link against the page, but no email will be sent.
Any link created in this manner will be logged in the CSV of the landing page for the request. This lets you keep a record of the links that have been generated.
PARAMS
Parameter | Description |
---|---|
object | The email signup link from BookFunnel that the reader’s link will be generated against (required) |
The reader’s email address (required) |
Response
{ "status": "OK", "message": "Link created.", "link": Reader's download link, "code": Reader's download code }
/v1/email_link
Create a unique link against an opt-in landing page on BookFunnel and then email that link to the reader.
PARAMS
Parameter | Description |
---|---|
object | The email signup link from BookFunnel that the reader’s link will be generated against (required) |
The reader’s email address (required) | |
first_name | The reader’s first name (optional) |
last_name | The reader’s last name (optional) |
subject | The subject line you want in the email (optional) Default: Here’s “{{title}}” by {{author}} |
heading | The heading you would like to include at the top of the email (optional) Default: {{book_title}} |
message | The message you would like to include in the email (optional) Default: If you have any trouble getting your book, click the help link at the top of the page. Someone from our support team will be happy to lend a hand! |
Response
{ "status": "OK", "message": "Email queued.", "link": Reader's download link, "code": Reader's download code }
API Testing
/v1/test
Test your API key and receive a response.
Response
{ "status": "OK", "message": "Looks good!", "name": Account holder's name, "email": Account holder's email }