MENU

API Documentation

Introduction

The WritersDB API gives you programmatic access to view and modify your data, including your titles, markets, and submissions. With this API, you are empowered to create a variety of tools and conveniences for yourself, such as:

  • Widgets for your desktop or a web-based dashboard
  • Automations via a platform like Zapier or n8n
  • Integrations with tools like Apple Shortcuts, Notion, Airtable, etc.
  • A complete app of your own devising

The API is available to Pro users. You can check your account status, and upgrade to Pro if you’re currently on the Free plan, on your Account page.

 
Continue to Authentication

Authentication

Creating an API Key

API keys are managed from your API Keys page, which is accessible from your Account page. A Pro account is required to create API keys.

When creating a key you assign a label (optional), choose an access level, and optionally set an expiration date. The raw key is displayed exactly once upon creation — copy and store it somewhere secure, as it cannot be retrieved again.

Access Levels

  • Read — permits GET requests that list and retrieve your data.
  • Read+Write — permits all read operations, plus POST requests that create or modify data.

Sending Your API Key

Each API request should include the Authorization header using the Bearer scheme:

Authorization: Bearer YOUR_API_KEY

Example Request

curl -H "Authorization: Bearer YOUR_API_KEY" \
	https://www.writersdb.com/api/titles/list

Error Responses

All error responses return a JSON object with an error message and a numeric code matching the HTTP status:

{"error": "Unauthorized", "code": 401}
CodeMeaning
400Bad request — a required parameter is missing or has an invalid value
401Unauthorized — API key is missing, invalid, or expired
403Forbidden — a Pro account is required, or a read-only key was used on a write endpoint
404Not found — the resource or endpoint does not exist
500Server error — an unexpected internal error occurred
Back to Introduction
Continue to Titles

Titles

Get a list of titles

Endpoint
https://www.writersdb.com/api/titles/list

Returns all titles belonging to the authenticated user.

The Request

Request type: GET

Permission required: Read

The Response

Example response

[
  {
    "id": 1,
    "title": "The Last Signal",
    "ms_url": "https://docs.google.com/document/d/...",
    "notes": "Revised draft as of March 2025",
    "wordcount": 4200
  },
  {
    "id": 2,
    "title": "Salt and Stars",
    "ms_url": "",
    "notes": "",
    "wordcount": 2800
  }
]

Response fields

FieldTypeDescription
idintegerUnique identifier for the title
titlestringTitle of the piece
ms_urlstringURL to the manuscript; may be empty
notesstringUser notes about the piece; may be empty
wordcountintegerMost recent recorded word count; 0 if none has been recorded

Create a new title

Endpoint
https://www.writersdb.com/api/titles/create

Creates a new title for the authenticated user.

The Request

Request type: POST

Permission required: Read+Write

Example request body

title=The+Last+Signal&ms_url=https%3A%2F%2Fdocs.google.com%2F...&notes=First+draft

Request parameters

ParameterRequiredTypeDescription
titleYesstringTitle of the piece
ms_urlNostringURL pointing to the manuscript file
notesNostringFree-form notes about the piece

The Response

Example response

{"id": 42}

Edit an existing title

Endpoint
https://www.writersdb.com/api/titles/edit/{id}

Updates fields on an existing title. Only fields included in the request are changed; omitted fields are left as-is.

The Request

Request type: POST

Permission required: Read+Write

Example request

POST https://www.writersdb.com/api/titles/edit/42

title=The+Last+Signal+%28Revised%29&notes=Second+draft+complete

Request parameters

ParameterRequiredTypeDescription
titleNostringNew title text; omit to leave unchanged
ms_urlNostringNew manuscript URL; pass an empty string to clear
notesNostringNew notes; pass an empty string to clear

The Response

Example response

{"success": true}

Set a word count

Endpoint
https://www.writersdb.com/api/titles/wordcount

Records the total word count for a given title on a given date. If a count already exists for that title and date it is updated; otherwise a new count is recorded.

The Request

Request type: POST

Permission required: Read+Write

Example request body

title_id=42&words=12500&date=2026-04-03

Request parameters

ParameterRequiredTypeDescription
title_idYesintegerID of the title to update
wordsYesintegerTotal word count for this title as of the given date
dateNodate string (YYYY-MM-DD)Date the word count applies to; defaults to today if omitted

The Response

Example response

{"success": true}
Continue to Markets

Markets

Get a list of markets

Endpoint
https://www.writersdb.com/api/markets/list

Returns all markets available to the authenticated user: markets they own plus markets they subscribe to.

The Request

Request type: GET

Permission required: Read

The Response

Example response

[
  {
    "id": 7,
    "name": "Clarkesworld",
    "responsetime": "6 weeks",
    "payrate": "8 cents/word",
    "maxwords": 16000,
    "tags": ["fiction", "sf"],
    "ownership": "subscribed"
  },
  {
    "id": 12,
    "name": "My Local Zine",
    "responsetime": null,
    "payrate": "",
    "maxwords": null,
    "tags": [],
    "ownership": "owned"
  }
]

Response fields

FieldTypeDescription
idintegerUnique identifier for the market
namestringName of the market
responsetimestring or nullTypical response time; freeform text (e.g., "6 weeks", "Quarterly", "unknown"); may be null
payratestringPay rate description; may be empty
maxwordsinteger or nullMaximum word count accepted
tagsarray of stringsCategory tags associated with the market
ownershipstringowned if created by the authenticated user; subscribed otherwise

Get market details

Endpoint
https://www.writersdb.com/api/markets/detail/{id}

Returns the full detail record for a single market.

The Request

Request type: GET

Permission required: Read

The Response

Example response

{
  "id": 7,
  "name": "Clarkesworld",
  "editor": "Neil Clarke",
  "web": "https://clarkesworldmagazine.com",
  "email": "submissions@clarkesworldmagazine.com",
  "emailsubs": "",
  "tel": "",
  "fax": "",
  "addr1": "",
  "addr2": "",
  "city": "",
  "state": "",
  "zip": "",
  "country": "",
  "responsetime": "6 weeks",
  "payrate": "8 cents/word",
  "maxwords": 16000,
  "simsubs": false,
  "multsubs": false,
  "reprints": false,
  "esubs": 2,
  "deadline": null,
  "entryfee": "",
  "shared": true,
  "tags": ["fiction", "sf"],
  "notes": "Science fiction and fantasy only.",
  "avg_response": 14,
  "ownership": "subscribed"
}

Response fields

FieldTypeDescription
idintegerUnique identifier
namestringMarket name
editorstringEditor name; may be empty
webstringWebsite URL; may be empty
emailstringContact email; may be empty
emailsubsstringSeparate submission email address; may be empty
telstringPhone number; may be empty
faxstringFax number; may be empty
addr1stringMailing address line 1; may be empty
addr2stringMailing address line 2; may be empty
citystringCity; may be empty
statestringState or province; may be empty
zipstringPostal code; may be empty
countrystringCountry; may be empty
responsetimestring or nullTypical response time; freeform text (e.g., "6 weeks", "Quarterly", "unknown"); may be null
payratestringPay rate description; may be empty
maxwordsinteger or nullMaximum word count accepted
simsubsbooleanWhether simultaneous submissions to other markets are accepted
multsubsbooleanWhether multiple submissions from the same author are accepted
reprintsbooleanWhether reprints are accepted
esubs0, 1, or 2Delivery method: 0 = Postal only, 1 = Postal AND e-mail, 2 = E-mail only
deadlinedate string or nullSubmission deadline in YYYY-MM-DD format, or null if open
entryfeestringEntry fee description (for contests); may be empty
sharedbooleanWhether this market is shared with other WritersDB users
tagsarray of stringsCategory tags
notesstringUser notes about this market
avg_responseinteger or nullAverage response time in days, calculated from recorded responses
ownershipstringowned or subscribed

Create a new market

Endpoint
https://www.writersdb.com/api/markets/create

Creates a new market owned by the authenticated user.

The Request

Request type: POST

Permission required: Read+Write

Example request body

market=Strange+Horizons&web=https%3A%2F%2Fstrangehorizons.com&responsetime=12+weeks&payrate=8+cents%2Fword&simsubs=0&tags=fiction%2Csf

Request parameters

ParameterRequiredTypeDescription
marketYesstringName of the market
editorNostringEditor or contact name
webNostringWebsite URL
emailNostringGeneral contact email
emailsubsNostringSubmission email address, if different from the contact email
telNostringPhone number
addr1NostringMailing address line 1
addr2NostringMailing address line 2
cityNostringCity
stateNostringState or province
zipNostringPostal code
countryNostringCountry
responsetimeNostringTypical response time; freeform text (e.g., "6 weeks", "Quarterly")
payrateNostringPay rate description
maxwordsNointegerMaximum word count accepted
simsubsNo0 or 1Whether simultaneous submissions to other markets are accepted
multsubsNo0 or 1Whether multiple submissions from the same author are accepted
reprintsNo0 or 1Whether reprints are accepted
esubsNo0, 1, or 2Delivery method: 0 = Postal only, 1 = Postal AND e-mail, 2 = E-mail only (default: 0)
deadlineNodate stringSubmission deadline in YYYY-MM-DD format
entryfeeNostringEntry fee description (for contests)
tagsNoarray or comma-separated stringTags from your existing tag list; unrecognized tags are silently ignored
notesNostringFree-form notes about this market
sharedNo0 or 1Whether to share this market with other WritersDB users (default: 0)

The Response

Example response

{"id": 88}

Edit an existing market

Endpoint
https://www.writersdb.com/api/markets/edit/{id}

Updates fields on an existing market. Only fields included in the request are changed; omitted fields retain their current values. Accepts all the same parameters as Create a new market (above), all optional.

The Request

Request type: POST

Permission required: Read+Write

Example request

POST https://www.writersdb.com/api/markets/edit/88

responsetime=10+weeks&payrate=9+cents%2Fword

Request parameters

See above, under “Create a new market.”

The Response

Example response

{"success": true}
Back to Titles
Continue to Submissions

Submissions

Get a list of submissions

Endpoint
https://www.writersdb.com/api/submissions/list

Returns all submissions belonging to the authenticated user. Optionally filter by status using the status query parameter.

The Request

Request type: GET

Permission required: Read

Example request

GET https://www.writersdb.com/api/submissions/list?status=pending

Request parameters

ParameterRequiredTypeDescription
statusNostringFilter results by status. Accepted values: pending, sold, rejected, withdrawn. Omit to return all submissions.

The Response

Example response

[
  {
    "id": 101,
    "title": "The Last Signal",
    "title_id": 1,
    "market": "Clarkesworld",
    "market_id": 7,
    "datesent": "2025-03-10",
    "status": "pending",
    "custom_status_id": null,
    "status_type": null,
    "responsedate": null,
    "notes": ""
  }
]

Response fields

FieldTypeDescription
idintegerUnique identifier for the submission
titlestringTitle of the submitted piece
title_idintegerID of the title record
marketstringName of the market submitted to
market_idintegerID of the market record
datesentdate stringDate the submission was sent (YYYY-MM-DD)
statusstringCurrent status: pending, sold, rejected, withdrawn, or the name of a custom status
custom_status_idinteger or nullID of the custom status, if one is in use; otherwise null
status_type1, 2, or 3; or nullCategory of the custom status: 1 = Pending, 2 = Closed/Success, 3 = Closed/Failure; null if a standard status is in use
responsedatedate string or nullDate a response was received (YYYY-MM-DD), or null if still pending
notesstringNotes about this submission; may be empty

Get submission details

Endpoint
https://www.writersdb.com/api/submissions/detail/{id}

Returns the full detail record for a single submission.

The Request

Request type: GET

Permission required: Read

The Response

Example response

{
  "id": 101,
  "title": "The Last Signal",
  "title_id": 1,
  "market": "Clarkesworld",
  "market_id": 7,
  "datesent": "2025-03-10",
  "status": "sold",
  "custom_status_id": null,
  "status_type": null,
  "responsedate": "2025-04-01",
  "amtpaid": "336.00",
  "notes": "Accepted for June issue"
}

Response fields

Returns all the same fields as the list endpoint, plus:

FieldTypeDescription
amtpaiddecimalPayment amount received; “0.00″ if unpaid or not applicable

Send a submission

Endpoint
https://www.writersdb.com/api/submissions/send

Records a new submission of a title to a market.

The Request

Request type: POST

Permission required: Read+Write

Example request body

title_id=1&market_id=7&datesent=2025-03-10&notes=Standard+submission

Request parameters

ParameterRequiredTypeDescription
title_idYesintegerID of the title being submitted
market_idYesintegerID of the market being submitted to
datesentNodate stringDate sent in YYYY-MM-DD format; defaults to today
notesNostringFree-form notes about this submission
custom_status_idNointegerID of a custom status to apply at creation time; see List custom statuses below

The Response

Example response

{"success": true}

Record a submission response

Endpoint
https://www.writersdb.com/api/submissions/response/{id}

Records a market’s response to an existing submission. Provide either status or custom_status_id, but not both.

The Request

Request type: POST

Permission required: Read+Write

Example request body

POST https://www.writersdb.com/api/submissions/response/101

status=sold&responsedate=2025-04-01&amtpaid=336.00&notes=Accepted+for+June+issue

Request parameters

ParameterRequiredTypeDescription
statusYes*stringResponse status: pending, sold, rejected, or withdrawn. Required unless custom_status_id is provided.
custom_status_idYes*integerID of a custom status to apply instead of a standard status value
responsedateNodate stringDate the response was received in YYYY-MM-DD format; defaults to today
amtpaidNodecimalPayment amount received (e.g. 336.00); relevant when status is sold
notesNostringNotes about this response

The Response

Example response

{"success": true}

List custom statuses

Endpoint
https://www.writersdb.com/api/submissions/list_custom_statuses

Returns all custom submission statuses you have defined. Use the returned id values as custom_status_id when sending a submission or recording a response.

The Request

Request type: GET

Permission required: Read

The Response

Example response

[
  {"id": 3, "name": "Shortlisted", "status_type": 1},
  {"id": 4, "name": "R&R Requested", "status_type": 1}
]

Response fields

FieldTypeDescription
idintegerID used to reference this custom status in other endpoints
namestringDisplay name of the custom status
status_type1, 2, or 3Category of this custom status: 1 = Pending, 2 = Closed/Success, 3 = Closed/Failure
Back to Markets