Organization API: Org Staff Ops
Every Organization API operation tagged Org Staff Ops.
Base URL: https://api.coritan.com/api/v1. Paths below are complete.
To try these requests in the browser, open the interactive Organization API reference.
Operations
Section titled Operations| Method | Path | Summary |
|---|---|---|
| GET | /api/v1/orgs/{org_slug}/staff/ops-summary |
The numbers on the console's badges and the desk, for one audience view |
| GET | /api/v1/orgs/{org_slug}/staff/orders |
The brand's orders, paying customers first and newest first |
| GET | /api/v1/orgs/{org_slug}/staff/orders/stats |
Staff orders stats |
| GET | /api/v1/orgs/{org_slug}/staff/orders/{service_id} |
One order: the order row, its customer, its invoices and its server |
| GET | /api/v1/orgs/{org_slug}/staff/refund-requests |
The refund requests, oldest first, so the longest wait is decided first |
| GET | /api/v1/orgs/{org_slug}/staff/refund-requests/{request_id} |
Staff refund request |
| POST | /api/v1/orgs/{org_slug}/staff/refund-requests/{request_id}/approve |
Staff approve refund request |
| POST | /api/v1/orgs/{org_slug}/staff/refund-requests/{request_id}/reject |
Staff reject refund request |
| GET | /api/v1/orgs/{org_slug}/staff/search |
Search accounts, invoices, orders, servers, tickets and coupons from one box |
The numbers on the console's badges and the desk, for one audience view
Section titled The numbers on the console's badges and the desk, for one audience viewGET /api/v1/orgs/{org_slug}/staff/ops-summary
The numbers on the console's badges and the desk, for one audience view.
These count the whole brand and are the same for every member:
open_tickets, pending_refunds, unpaid_invoices,
unpaid_invoices_24h, pending_services, orders_24h,
customers, community_open, chat_reports_open, sla_breached,
signups_24h, dunning_failing, servers_attention,
deliveries_attention (game network purchases whose delivery failed or
that the network has not confirmed within 10 minutes) and
audience_counts (paid and free totals, whatever the view). They are
normally under a minute old, and the first request after a quiet spell can
show numbers a few minutes old.
assigned_to_me and unread_alerts are for the member who asks and
are always current.
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
org_slug |
path | string | yes |
audience |
query | string or null | no |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
The brand's orders, paying customers first and newest first
Section titled The brand's orders, paying customers first and newest firstGET /api/v1/orgs/{org_slug}/staff/orders
The brand's orders, paying customers first and newest first. Every
filter is applied before the page is cut, so limit and offset walk
exactly the orders that match. status_filter takes the words of its
description, so a column title on the orders board lists exactly the
orders in that column; plan, product and product_id narrow to
one plan, kind of product or product, and created_after and
created_before to the days the orders were placed. channel,
first_channel, source, medium, campaign, device,
heard_about and coupon_campaign keep the orders whose attribution
record holds exactly that word (the Acquisition report's rows open the
orders behind them this way). An order with no attribution record matches
none of them, and a channel or first_channel that is not a channel
key answers 422 with the keys that are.
Parameters
Section titled Parameters| Name | In | Type | Required | Description |
|---|---|---|---|---|
org_slug |
path | string | yes | |
q |
query | string or null | no | |
customer_id |
query | integer or null | no | |
status_filter |
query | string or null | no | An order status (pending, provisioning, active, suspended, cancelled, terminated or failed), all, stuck (paid for, or never invoiced, and not built yet: pending, provisioning or failed), or a column of the orders board: pending_payment (invoiced and not paid), building (paid for and being built), install_failed, active_recent (went live in the last 7 days), suspended or canceled_recent (cancelled or terminated in the last 7 days). A board word lists exactly the orders in that column. Any other word lists nothing. |
plan |
query | string or null | no | A plan, which is a product's exact name, such as the name the Insights plan rows carry. |
product |
query | string or null | no | A kind of product, such as container or vps, as the Insights product rows carry. Letter case does not matter. |
product_id |
query | integer or null | no | One product, by its id. |
created_after |
query | string (date) or null | no | Only orders placed on or after this day, YYYY-MM-DD, counted in the brand's time zone. |
created_before |
query | string (date) or null | no | Only orders placed on or before this day, YYYY-MM-DD, counted in the brand's time zone. A created_after that is later than created_before answers 422. |
channel |
query | string or null | no | The channel of the order's last touch, one of: paid_search, paid_social, display, organic_search, organic_social, email, affiliate, referral, direct, other. Any other word answers 422. |
first_channel |
query | string or null | no | The channel of the order's first touch, one of: paid_search, paid_social, display, organic_search, organic_social, email, affiliate, referral, direct, other. Any other word answers 422. |
source |
query | string or null | no | The source of the order's last touch, such as google or reddit.com, exactly as the Acquisition report writes it. |
medium |
query | string or null | no | The medium of the order's last touch, such as cpc, organic or email. |
campaign |
query | string or null | no | The utm_campaign of the order's last touch. |
device |
query | string or null | no | The device the order was placed on: desktop, mobile, tablet or unknown. |
heard_about |
query | string or null | no | The buyer's answer to How did you first hear about us, such as reddit or friend. |
coupon_campaign |
query | string or null | no | The campaign of the coupon the order used. |
audience |
query | string or null | no | |
limit |
query | integer | no | Default: 50. |
offset |
query | integer | no | Default: 0. |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
Staff orders stats
Section titled Staff orders statsGET /api/v1/orgs/{org_slug}/staff/orders/stats
One count per order status for the tiles above the list, under the
audience the request carries. cancelled is spelled as the status
value is (the way the invoice stats spell theirs); stuck folds
pending, provisioning and failed orders that are paid for (or were never
invoiced), from the clause the stuck list filters with.
The counts cover the whole brand. They are normally under a minute old, and the first request after a quiet spell can show numbers a few minutes old. The order list is always current, so a tile can trail a new order that the list already shows.
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
org_slug |
path | string | yes |
audience |
query | string or null | no |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
One order: the order row, its customer, its invoices and its server
Section titled One order: the order row, its customer, its invoices and its serverGET /api/v1/orgs/{org_slug}/staff/orders/{service_id}
One order: the order row, its customer, its invoices and its server.
attribution is where the buyer came from, or null for an order the storefront did
not place (a staff order, a renewal) or one placed before attribution was recorded. It
holds the first and last touch (each with its channel as {key, label}, the
ad network and the UTM fields, or null when no visit was seen), the click_ids
with their ad network, the buyer's heard_about answer, the coupon and its
campaign, the affiliate_code, device_type, country_code, the consent the
buyer had, whether the buyer was a new customer (is_new_customer) and the order free
(is_free), and which identifiers we hold (identifiers). address.state is
kept or truncated and address.network its network: the whole address is never
sent. order.channel is the last touch's channel.
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
service_id |
path | integer | yes |
org_slug |
path | string | yes |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
The refund requests, oldest first, so the longest wait is decided first
Section titled The refund requests, oldest first, so the longest wait is decided firstGET /api/v1/orgs/{org_slug}/staff/refund-requests
The refund requests, oldest first, so the longest wait is decided first.
pending is the size of the whole queue still to decide, whatever the
status and search, which is what the consoles badge. With
with_total=true the answer adds total (the requests the status and
search match, counted from the same clause as the page), limit,
offset and counts (all and each status, for the same search).
Without it the answer keeps its older shape: status, pending,
items and can_decide.
Parameters
Section titled Parameters| Name | In | Type | Required | Description |
|---|---|---|---|---|
org_slug |
path | string | yes | |
status |
query | string or null | no | One request status, or all. Left out, the queue still to decide (pending). |
q |
query | string or null | no | Invoice number, customer email, name or company, service hostname, or a request, invoice or customer number. |
limit |
query | integer | no | Default: 50. |
offset |
query | integer | no | Default: 0. |
with_total |
query | boolean | no | Adds total, limit, offset and per-status counts for the same search. Default: False. |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
Staff refund request
Section titled Staff refund requestGET /api/v1/orgs/{org_slug}/staff/refund-requests/{request_id}
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
request_id |
path | integer | yes |
org_slug |
path | string | yes |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
Staff approve refund request
Section titled Staff approve refund requestPOST /api/v1/orgs/{org_slug}/staff/refund-requests/{request_id}/approve
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
request_id |
path | integer | yes |
org_slug |
path | string | yes |
Request body
Section titled Request bodyapplication/json (required)
| Field | Type | Required |
|---|---|---|
resolution |
string | no |
note |
string or null | no |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
Staff reject refund request
Section titled Staff reject refund requestPOST /api/v1/orgs/{org_slug}/staff/refund-requests/{request_id}/reject
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
request_id |
path | integer | yes |
org_slug |
path | string | yes |
Request body
Section titled Request bodyapplication/json (required)
| Field | Type | Required |
|---|---|---|
note |
string | yes |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |
Search accounts, invoices, orders, servers, tickets and coupons from one box
Section titled Search accounts, invoices, orders, servers, tickets and coupons from one boxGET /api/v1/orgs/{org_slug}/staff/search
Search accounts, invoices, orders, servers, tickets and coupons from one box.
Results are always current. The answer lists up to 20 accounts, 10 invoices, 10 orders, 10 servers, 10 tickets and 6 coupons.
Accounts, invoices and orders list paying ones first and the newest first
within each group. The search reads the newest 300 paying matches and the
newest 300 others of each kind (for invoices, the highest numbers), so a
paying match is listed however many newer matches do not pay. A very broad
needle lists the newest matches, not every match. Under the paid or
free audience only that group is read, so the list is never empty while
matches of that audience exist. Tickets are listed newest activity first,
inside the audience.
Accounts whose address or handle starts with the needle are read first,
and when twenty or more start with it the other fields are not searched.
A word with an @ is matched against addresses only. A server is found
by the start of its UUID (8 characters or more). A needle that is a whole
UUID also finds every service whose record names it. Coupons need Tier 3
support or above.
Parameters
Section titled Parameters| Name | In | Type | Required |
|---|---|---|---|
org_slug |
path | string | yes |
q |
query | string | yes |
audience |
query | string or null | no |
Responses
Section titled Responses| Status | Meaning |
|---|---|
200 |
Success. |
422 |
The request is not valid. detail lists each problem. |