DevelopersHow to connect an assistantKeys
Reference/Cards/Read

Search cards

GEThttps://api.getwerk.ai/api/v1/cards

The key's person's cards across their projects, listed by filters or searched by words.

With q, Werk looks in the cards' titles, descriptions, updates, lists, photos, voice notes and documents, by words and by meaning, best match first. Without q, the cards the filters keep are listed in the order sort and order give, each with its own default.

Authorization

AuthorizationheaderRequired

Authorization: Bearer <key> Authentication

Headers

Werk-Localestring

The language tag Werk writes the answer's own words in, such as step names and history lines, matched to a language it serves; a card's text stays as written. At a project's paths, the reads of its cards and steps, of a card, its update photos, a file and its reminders, and of follow and reminder invitations, and a document's read-now and consent, take the language of the person's chat with Werk in that project first, while it has one. Without either, the language Werk uses with the person the key or the connection acts for.

Query parameters

qstring

The words to look for; left out, cards are listed by the other filters.

From 1 to 200 characters
instring

Where to look for the words, comma separated: title, description, card, update, list, photo, voice_note, document; left out, everywhere.

projectsstring

Project ids, comma separated; left out, every project of the key's person.

stateenum

open, done, archived or all; left out, all with q or a span of when cards were made, changed or done, and open otherwise.

Allowed valuesopendonearchivedall
holderenum or string, uuid

A person's id to keep the cards they hold, or none for free cards.

Allowed valuesnone
authorstring, uuid

A person's id, to keep the cards they created.

followingenum

true keeps the cards the key's person follows.

Allowed valuestrue
stepstring

A step's id, to keep the cards on it; only with exactly one project in projects.

Up to 64 characters
dueenum

none keeps the cards with no due date; it cannot go with dueFrom or dueBefore.

Allowed valuesnone
dueFromstring, date or string, date-time

Keeps cards due from this day or moment on: YYYY-MM-DD in the key's person's time zone, or an ISO 8601 date and time with Z or an offset.

dueBeforestring, date or string, date-time

Keeps cards due before this day or moment, in the same forms as dueFrom.

createdFromstring, date or string, date-time

Keeps cards created from this day or moment on, in the same forms as dueFrom.

createdBeforestring, date or string, date-time

Keeps cards created before this day or moment.

updatedFromstring, date or string, date-time

Keeps cards changed from this day or moment on.

updatedBeforestring, date or string, date-time

Keeps cards changed before this day or moment.

doneFromstring, date or string, date-time

Keeps cards that reached their last step from this day or moment on.

doneBeforestring, date or string, date-time

Keeps cards that reached their last step before this day or moment.

sortenum

relevance, only with q; board, the project's own order, with exactly one project and a state other than all; updated, created, due or number. Left out, relevance with q, board for one project, updated otherwise.

Allowed valuesrelevanceboardupdatedcreatedduenumber
orderenum

The order of the sort; left out, each sort's own: oldest first for board, due and number, newest first for the rest.

Allowed valuesascdesc
limitinteger

How many cards a page holds.

From 1 to 100
Default50
afterstring

The cursor from the previous page's nextCursor; left out, the first page.

From 1 to 512 characters

Response

200 The cards found.

itemsarray of objects

The cards found, in the order asked.

Up to 100 items
Show properties of itemsHide properties of items
projectobject

The card's project.

Show properties of projectHide properties of project
projectIdstring, uuid

The project's id.

conversationIdstring, uuid

The id Werk's apps use for the key's person's view of the project.

namestring

The project's name.

finalStepobject

The project's last step, the one that ends the work.

Show properties of finalStepHide properties of finalStep
idstring

The step's id.

labelstring

The step's name.

itemobject

The card.

Show properties of itemHide properties of item
outcomeenum

completed when the card is on its project's last step, not_completed when it was archived before it, open otherwise.

Allowed valuesopencompletednot_completed
idstring, uuid

The card's id.

refstring or null

The card's number as people write it, with # before it.

titlestring

The card's title, as written.

languagestring or null

The language the card's title and description are written in.

titleTranslationobject

The title in the reader's language, when it is written in another.

Show properties of titleTranslationHide properties of titleTranslation
languagestring

The reader's language the text is translated into.

From 2 to 64 characters
stateenum

ready when text holds the translation, pending while it is being made, failed when it could not be made, paused when no plan pays for translations now.

Allowed valuesreadypendingfailedpaused
textstring

The translated text, present once ready.

statusobject

The step the card is on, with where that step sits in the work.

Show properties of statusHide properties of status
keystring

The id of the step the card is on.

At least 1 character
labelstring

The step's name.

At least 1 character
categoryenum

open on a new step, done on the project's last step, active on any other step.

Allowed valuesopenactivedone
bucketenum

The kind of step the card is on; a step that ends the work reads in_progress while it is not the project's last step.

Allowed valuesnewin_progresswaitingresolvedclosed
labelLanguagestring

The language the step's name is written in; absent for a step name Werk writes in the reader's language itself.

From 2 to 64 characters
labelTranslationobject

The step's name in the reader's language, when it is written in another.

Show properties of labelTranslationHide properties of labelTranslation
languagestring

The reader's language the text is translated into.

From 2 to 64 characters
stateenum

ready when text holds the translation, pending while it is being made, failed when it could not be made, paused when no plan pays for translations now.

Allowed valuesreadypendingfailedpaused
textstring

The translated text, present once ready.

dueNoticeLeadenum

How long before the due date its holder and followers get the due notice; none sends no notice.

Allowed valuesnoneat_due15_minutes1_hour2_hours1_day2_days
dueSetByobject or null

Who set the due moment; present only for a due date with a time.

Show properties of dueSetByHide properties of dueSetBy
displayNamestring

That person's name.

dueobject or null

The card's due date, or null when it has none.

Show properties of dueHide properties of due

One of 2 shapes, told apart by kind:

kinddate
kindenum

date for a due day with no time, datetime for a due moment.

Allowed valuesdate
datestring, date

The due day, as YYYY-MM-DD.

kinddatetime
kindenum

date for a due day with no time, datetime for a due moment.

Allowed valuesdatetime
atstring, date-time

The due moment, as an ISO 8601 date and time with its offset.

enteredTimeZonestring or null

The time zone the due moment was given in, when known.

assigneeobject or null

The card's holder, or null when the card is free.

Show properties of assigneeHide properties of assignee
personIdstring, uuid

The holder's person id.

displayNamestring

The holder's name as the project shows it.

initialsstring

The holder's initials, for an avatar with no photo.

photoobject

The holder's photo, when they have one.

Show properties of photoHide properties of photo
personIdstring, uuid

The person whose photo it is.

versioninteger

The photo's version, which changes with the photo; its read takes it to fetch the current one.

At least 1
versioninteger

The card's version, which grows with every change to it.

At least 1
numberinteger or null

The card's number in its project, unique there and never reused.

At least 1
currentStepobject or null

The card's step among its project's steps, as the project defines it.

Show properties of currentStepHide properties of currentStep
idstring

The step's id; a change of step sends it as stepId.

At least 1 character
labelstring

The step's name.

At least 1 character
bucketenum

The kind of step: new for an open step, in_progress or waiting for one in between, resolved or closed for one that ends the work.

Allowed valuesnewin_progresswaitingresolvedclosed
labelLanguagestring

The language the step's name is written in; absent for a step name Werk writes in the reader's language itself.

From 2 to 64 characters
labelTranslationobject

The step's name in the reader's language, when it is written in another.

Show properties of labelTranslationHide properties of labelTranslation
languagestring

The reader's language the text is translated into.

From 2 to 64 characters
stateenum

ready when text holds the translation, pending while it is being made, failed when it could not be made, paused when no plan pays for translations now.

Allowed valuesreadypendingfailedpaused
textstring

The translated text, present once ready.

archivedboolean

True when the card is archived: it has left the working lists and stays readable and searchable.

countsobject

How much the card holds.

Show properties of countsHide properties of counts
photosinteger

Photos on the card.

At least 0
updatesinteger

Updates on the card.

At least 0
documentsinteger

Documents on the card.

At least 0
checklistobject

The card's list: its items checked and in all; absent when the card has no list.

Show properties of checklistHide properties of checklist
doneinteger

List items checked.

At least 0
totalinteger

List items in all.

At least 0
allowedActionsarray of enums

The changes the key's person may make to this card by hand now, by action name.

Allowed valuestake_cardassign_cardgive_back_cardmove_cardarchive_cardunarchive_cardedit_cardset_card_dueadd_updatecreate_reminderlink_duplicateadd_entriesrename_entryremove_entryreorder_entriesfollow_cardunfollow_cardfollow_invitationtick_entryuntick_entryset_due_notice
foundByarray of enums

With words, how the card was found: by its words, by meaning, or both; empty without words.

Allowed valueswordsmeaning
Up to 2 items
matchesarray of objects

With words, where on the card they matched.

Show properties of matchesHide properties of matches

One of 6 shapes, told apart by in:

intitle
inenum

Where it matched: the title, the description, the card's text by meaning, an update, a list item, a photo, a voice note or a document.

Allowed valuestitle
incard
inenum

Where it matched: the title, the description, the card's text by meaning, an update, a list item, a photo, a voice note or a document.

Allowed valuescard
indescription
inenum

Where it matched: the title, the description, the card's text by meaning, an update, a list item, a photo, a voice note or a document.

Allowed valuesdescription
textstring or null

The piece of text that matched, or null when none is quoted.

inupdatephotovoice_note
inenum

Where it matched: the title, the description, the card's text by meaning, an update, a list item, a photo, a voice note or a document.

Allowed valuesupdatephotovoice_note
textstring or null

The piece of text that matched, or null when none is quoted.

byobject or null

Who added what matched, or null when no longer known.

Show properties of byHide properties of by

One of 3 shapes, told apart by kind:

kinduser
kindenum

user for a person; connector or schedule for a change Werk made without one.

Allowed valuesuser
displayNamestring

The person's name as the project shows it.

At least 1 character
initialsstring

The person's initials, for an avatar with no photo.

isViewerboolean

True when the person is the key's own person.

photoobject

The person's photo, when they have one.

Show properties of photoHide properties of photo
personIdstring, uuid

The person whose photo it is.

versioninteger

The photo's version, which changes with the photo; its read takes it to fetch the current one.

At least 1
viaobject

The connected app or API key the change came through; absent for a change made in Werk's apps.

Show properties of viaHide properties of via
kindenum

connection for an app connected by sign-in, key for an API key.

Allowed valuesconnectionkey
namestring

The app's or the key's name, as Werk shows it.

At least 1 character
verifiedboolean

True when Werk verified the app's identity.

labelstring

The caption Werk shows beside the change, in the reader's language.

At least 1 character
kindconnector
kindenum

user for a person; connector or schedule for a change Werk made without one.

Allowed valuesconnector
labelstring

The name Werk shows for a change made without a person.

At least 1 character
kindschedule
kindenum

user for a person; connector or schedule for a change Werk made without one.

Allowed valuesschedule
labelstring

The name Werk shows for a change made without a person.

At least 1 character
atstring

When what matched was added.

inlist
inenum

Where it matched: the title, the description, the card's text by meaning, an update, a list item, a photo, a voice note or a document.

Allowed valueslist
textstring

The piece of text that matched, or null when none is quoted.

byobject or null

Who added what matched, or null when no longer known.

Show properties of byHide properties of by

One of 3 shapes, told apart by kind:

kinduser
kindenum

user for a person; connector or schedule for a change Werk made without one.

Allowed valuesuser
displayNamestring

The person's name as the project shows it.

At least 1 character
initialsstring

The person's initials, for an avatar with no photo.

isViewerboolean

True when the person is the key's own person.

photoobject

The person's photo, when they have one.

Show properties of photoHide properties of photo
personIdstring, uuid

The person whose photo it is.

versioninteger

The photo's version, which changes with the photo; its read takes it to fetch the current one.

At least 1
viaobject

The connected app or API key the change came through; absent for a change made in Werk's apps.

Show properties of viaHide properties of via
kindenum

connection for an app connected by sign-in, key for an API key.

Allowed valuesconnectionkey
namestring

The app's or the key's name, as Werk shows it.

At least 1 character
verifiedboolean

True when Werk verified the app's identity.

labelstring

The caption Werk shows beside the change, in the reader's language.

At least 1 character
kindconnector
kindenum

user for a person; connector or schedule for a change Werk made without one.

Allowed valuesconnector
labelstring

The name Werk shows for a change made without a person.

At least 1 character
kindschedule
kindenum

user for a person; connector or schedule for a change Werk made without one.

Allowed valuesschedule
labelstring

The name Werk shows for a change made without a person.

At least 1 character
atstring

When what matched was added.

checkedboolean

For a list item, true when it is checked.

indocument
inenum

Where it matched: the title, the description, the card's text by meaning, an update, a list item, a photo, a voice note or a document.

Allowed valuesdocument
textstring

The piece of text that matched, or null when none is quoted.

byobject or null

Who added what matched, or null when no longer known.

Show properties of byHide properties of by

One of 3 shapes, told apart by kind:

kinduser
kindenum

user for a person; connector or schedule for a change Werk made without one.

Allowed valuesuser
displayNamestring

The person's name as the project shows it.

At least 1 character
initialsstring

The person's initials, for an avatar with no photo.

isViewerboolean

True when the person is the key's own person.

photoobject

The person's photo, when they have one.

Show properties of photoHide properties of photo
personIdstring, uuid

The person whose photo it is.

versioninteger

The photo's version, which changes with the photo; its read takes it to fetch the current one.

At least 1
viaobject

The connected app or API key the change came through; absent for a change made in Werk's apps.

Show properties of viaHide properties of via
kindenum

connection for an app connected by sign-in, key for an API key.

Allowed valuesconnectionkey
namestring

The app's or the key's name, as Werk shows it.

At least 1 character
verifiedboolean

True when Werk verified the app's identity.

labelstring

The caption Werk shows beside the change, in the reader's language.

At least 1 character
kindconnector
kindenum

user for a person; connector or schedule for a change Werk made without one.

Allowed valuesconnector
labelstring

The name Werk shows for a change made without a person.

At least 1 character
kindschedule
kindenum

user for a person; connector or schedule for a change Werk made without one.

Allowed valuesschedule
labelstring

The name Werk shows for a change made without a person.

At least 1 character
atstring

When what matched was added.

documentobject

For a document, which one and where.

Show properties of documentHide properties of document
idstring, uuid

The document's id.

filenamestring

The document's name.

pageinteger

The part of the document it matched in, counted from 1.

At least 1
totalinteger

How many cards match in all, past this page included.

At least 0
completeboolean

False when the search read as deep as it goes, so more cards may match than total says.

byMeaningboolean or null

With words, true when the search also looked by meaning; null without words.

nextCursorstring or null

The cursor that reads the next page as after, or null when none remains.

From 1 to 512 characters

Errors

400invalid_queryThe query is not in the form the route takes; the limit is in the unit of the input details.field names (characters for a text, entries for a list, the value for a number).
400invalid_card_queryThe request about cards or their files is not in the form its route takes, or names a day of a filter while the signed-in person's profile has no time zone; the limit is in the unit of the input details.field names (characters for a text, entries for a list, the value for a number).
401session_revokedThe request carries no session the server holds, or its session has ended.
401session_expiredThe session has expired.
404conversation_not_foundThe project the request names, or its chat, is not one the signed-in person is in.
409session_changedThe session changed while the request was in flight.
409cursor_expiredThe page cursor no longer fits the list as it stands or the arguments it was read with.
409project_profile_changedThe project's setup changed while the cards were read.
rate_limitedMore requests of this kind were sent than Werk takes within the time it counts them over.
500server_errorThe server could not complete the request, and it is not known whether a write it holds was made.
curl
curl "https://api.getwerk.ai/api/v1/cards?q=faucet" \
  -H "Authorization: Bearer wk_key_..."
TypeScript
const res = await fetch("https://api.getwerk.ai/api/v1/cards?q=faucet", {
  headers: {
    Authorization: "Bearer wk_key_...",
  },
});
const answer = await res.json();
200JSON
{
  "items": [
    {
      "project": {
        "projectId": "2f6c9e41-7a3b-4d58-9c1e-0b8d4f2a6e73",
        "conversationId": "9e3b1c75-4f2a-4d86-b0c9-5a7e2d1f8c36",
        "name": "Harbor Street kitchen",
        "finalStep": {
          "id": "paid",
          "label": "Paid"
        }
      },
      "item": {
        "outcome": "open",
        "id": "1a7d3f92-6b4e-4c15-8e2a-9f0c5b7d3e81",
        "ref": "#12",
        "title": "Replace the leaking sink faucet",
        "language": "en-US",
        "status": {
          "key": "waiting_parts",
          "label": "Waiting for parts",
          "category": "active",
          "bucket": "waiting"
        },
        "dueNoticeLead": "at_due",
        "due": null,
        "assignee": {
          "personId": "8a2e6c14-3f5d-4b9a-a7e2-61c0d9f4b3e8",
          "displayName": "Tom Okafor",
          "initials": "TO"
        },
        "version": 4,
        "number": 12,
        "currentStep": {
          "id": "waiting_parts",
          "label": "Waiting for parts",
          "bucket": "waiting"
        },
        "archived": false,
        "counts": {
          "photos": 1,
          "updates": 1,
          "documents": 0
        }
      },
      "foundBy": [
        "words"
      ],
      "matches": [
        {
          "in": "title"
        }
      ]
    }
  ],
  "total": 1,
  "complete": true,
  "byMeaning": true,
  "nextCursor": null
}