List imports
const url = 'https://api.sloose.com/orgs/org_9f3c/imports?mine=true&status=open&limit=100';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://api.sloose.com/orgs/org_9f3c/imports?mine=true&status=open&limit=100' \ --header 'Authorization: Bearer <token>'The org’s imports, most recently active first, a page at a time. mine keeps the ones the caller started (a token’s count as its creator’s). Every member sees every import; what each may do to one is a matter of §7’s roles, asked when they try.
The order is each import’s latest activity — the later of when it was last changed and when its last run ended — so it MOVES while somebody pages through it: an import changed, or whose run ends, between two pages moves ahead of the cursor — the next page does not show it, and it is at the top of the list read again. An import is never shown twice.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”The org id the session was issued for. A token for one org can never read another.
Example
org_9f3cThe org id the session was issued for. A token for one org can never read another.
Query Parameters
Section titled “Query Parameters”true for only the caller’s own.
Example
truetrue for only the caller’s own.
Only imports from this template.
Only imports from this template.
Only imports that write through this connection — the Connections pages’ count of the imports through one. An id that is none of the org’s connections finds none: it is a filter, not a connection the request uses, so it is never refused.
Only imports that write through this connection — the Connections pages’ count of the imports through one. An id that is none of the org’s connections finds none: it is a filter, not a connection the request uses, so it is never refused.
Only imports whose name contains this text, ignoring case (ASCII letters; any other character matches as typed). Blank asks for every import. Only its first 200 characters are searched for: a longer text is cut there, never refused. The next page is asked for with the same text.
Only imports whose name contains this text, ignoring case (ASCII letters; any other character matches as typed). Blank asks for every import. Only its first 200 characters are searched for: a longer text is cut there, never refused. The next page is asked for with the same text.
How many to return, at most 200; 100 when absent. Anything but a whole number above zero — 0, negative, a fraction, not a number — is the default, never an error.
Example
100How many to return, at most 200; 100 when absent. Anything but a whole number above zero — 0, negative, a fraction, not a number — is the default, never an error.
The nextCursor of the page before this one; absent for the first page. Opaque: it names a place in the list’s (activityAt, id) order, and a malformed one is 400 INVALID_CURSOR.
The nextCursor of the page before this one; absent for the first page. Opaque: it names a place in the list’s (activityAt, id) order, and a malformed one is 400 INVALID_CURSOR.
Responses
Section titled “Responses”A page of the imports.
object
object
The connection Target names; null until one is chosen.
The template this import was started from or saved as.
The template version it copied: “the template has moved on” compares this.
Who started it — the person, or the person a token acts as. Null only for an import a schedule started, which is nobody’s own.
The token held, when one was.
Where it stands. An import being deleted is not returned at all: it reads as gone the moment its delete is accepted.
Whichever step the wizard of the day left it on, as that wizard names it.
The write precondition: every change names the version it was made against, and a stale one is refused 409 IMPORT_CHANGED.
The run that holds the import; every other write is refused while one does.
Who has it open right now, one entry per person however many tabs, in the order they arrived — from the import’s room (GET …/live).
object
Their name, or their address when they have cleared it.
Pass as cursor for the next page; null when this was the last.
Example
{ "imports": [ { "status": "open" } ]}The query did not match the schema (issues carries the Zod issue list), or cursor is malformed (code: INVALID_CURSOR).
The error envelope every non-2xx answer uses.
object
Human-readable explanation.
Machine-readable reason. Absent on a few legacy 400s.
Examplegenerated
{ "error": "example", "code": "example"}No bearer, or one that is expired, revoked or no longer resolves to a member.
The error envelope every non-2xx answer uses.
object
Human-readable explanation.
Machine-readable reason. Absent on a few legacy 400s.
Examplegenerated
{ "error": "example", "code": "example"}The bearer’s role is too low, or it was issued for a different org.
The error envelope every non-2xx answer uses.
object
Human-readable explanation.
Machine-readable reason. Absent on a few legacy 400s.
Examplegenerated
{ "error": "example", "code": "example"}