{"openapi":"3.1.0","info":{"title":"Otto Business API","version":"1.0.0","description":"Your business's own data and cold email, for your own code. Make a key under Settings → Integrations → API keys and send it as `Authorization: Bearer otto_…`. Each key does only what its scopes allow (x-otto-scope on each operation), at most 60 requests a minute, and every use is logged. Nothing a key does reaches anyone without a person's approval in Reviews."},"servers":[{"url":"/hooks/api/v1"}],"components":{"securitySchemes":{"key":{"type":"http","scheme":"bearer","description":"otto_… from Settings"}}},"security":[{"key":[]}],"x-otto-scopes":{"contacts":"Contacts (read)","jobs":"Jobs (read)","invoices":"Invoices (read)","leads":"Leads and lookups","campaigns":"Cold campaigns","replies":"Cold email replies"},"paths":{"/contacts":{"get":{"summary":"List contacts, newest first","operationId":"get_contacts","parameters":[{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":100,"default":100}},{"name":"before","in":"query","description":"An id: rows older than it (the last page's next_before).","schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string"},"email":{"type":"string"},"phone":{"type":"string"},"company":{"type":"string"},"stage":{"type":"string"},"created_at":{"type":"string"},"updated_at":{"type":"string"}}}},"next_before":{"type":"integer"}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"contacts"}},"/jobs":{"get":{"summary":"List jobs, newest first (full version only)","operationId":"get_jobs","parameters":[{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":100,"default":100}},{"name":"before","in":"query","description":"An id: rows older than it (the last page's next_before).","schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array"},"next_before":{"type":"integer"}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"jobs"}},"/invoices":{"get":{"summary":"List invoices that are not drafts, newest first (full version only)","operationId":"get_invoices","parameters":[{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":100,"default":100}},{"name":"before","in":"query","description":"An id: rows older than it (the last page's next_before).","schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array"},"next_before":{"type":"integer"}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"invoices"}},"/credits":{"get":{"summary":"Credits left and how they were used","operationId":"get_credits","parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"balance":{"type":"integer"},"rule":{"type":"string"},"sent":{"type":"integer"},"kept":{"type":"integer"},"free":{"type":"integer"},"refunds":{"type":"integer"},"refund_days":{"type":"integer"},"billing":{"type":"boolean"},"billing_note":{"type":"string"}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"leads"}},"/usage":{"get":{"summary":"Settings → Usage: credits and this month","operationId":"get_usage","parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"balance":{"type":"integer"},"rule":{"type":"string"},"sent":{"type":"integer"},"kept":{"type":"integer"},"free":{"type":"integer"},"refunds":{"type":"integer"},"refund_days":{"type":"integer"},"billing":{"type":"boolean"},"billing_note":{"type":"string"},"month":{"type":"object","additionalProperties":true}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"leads"}},"/lookup":{"post":{"summary":"Look up who runs one website (free)","operationId":"post_lookup","parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"domain":{"type":"string"},"found":{"type":"boolean"},"email":{"type":"string"},"how":{"type":"string"},"mail_check":{"type":"string"},"confirmed":{"type":"boolean"},"catch_all":{"type":"boolean"},"person":{"type":"object","properties":{"name":{"type":"string"},"title":{"type":"string"}}},"person_phone":{"type":"string"},"people_named":{"type":"integer"},"tools":{"type":"array"},"signals":{"type":"array"},"linkedin":{"type":"string"},"about":{"type":"string"},"size_estimate":{"type":"object","additionalProperties":true},"state":{"type":"string"},"city":{"type":"string"},"us_how":{"type":"string"},"company":{"type":"string"},"why":{"type":"string"},"credits":{"type":"integer"},"repeat":{"type":"boolean"},"looked_up_at":{"type":"string"},"balance":{"type":"integer"}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"leads","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"website":{"type":"string"},"who":{"enum":["owner","marketing","sales","operations"],"default":"owner"}},"required":["website"]}}}}}},"/lookups":{"post":{"summary":"Look up up to 100 websites in the background (free)","operationId":"post_lookups","parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"state":{"enum":["running","done"]},"who":{"type":"string"},"asked":{"type":"integer"},"done":{"type":"integer"},"credits":{"type":"integer"},"results":{"type":"array","items":{"type":"object","properties":{"domain":{"type":"string"},"found":{"type":"boolean"},"email":{"type":"string"},"how":{"type":"string"},"mail_check":{"type":"string"},"confirmed":{"type":"boolean"},"catch_all":{"type":"boolean"},"person":{"type":"object","properties":{"name":{"type":"string"},"title":{"type":"string"}}},"person_phone":{"type":"string"},"people_named":{"type":"integer"},"tools":{"type":"array"},"signals":{"type":"array"},"linkedin":{"type":"string"},"about":{"type":"string"},"size_estimate":{"type":"object","additionalProperties":true},"state":{"type":"string"},"city":{"type":"string"},"us_how":{"type":"string"},"company":{"type":"string"},"why":{"type":"string"},"credits":{"type":"integer"},"repeat":{"type":"boolean"},"looked_up_at":{"type":"string"},"balance":{"type":"integer"}}}},"created_at":{"type":"string"},"finished_at":{"type":"string"}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"leads","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"websites":{"type":"array","items":{"type":"string"},"minItems":1,"maxItems":100},"who":{"type":"string"}},"required":["websites"]}}}}}},"/lookups/{batch_id}":{"get":{"summary":"A lookup batch's answers so far","operationId":"get_lookups_batch_id","parameters":[{"name":"batch_id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"state":{"enum":["running","done"]},"who":{"type":"string"},"asked":{"type":"integer"},"done":{"type":"integer"},"credits":{"type":"integer"},"results":{"type":"array","items":{"type":"object","properties":{"domain":{"type":"string"},"found":{"type":"boolean"},"email":{"type":"string"},"how":{"type":"string"},"mail_check":{"type":"string"},"confirmed":{"type":"boolean"},"catch_all":{"type":"boolean"},"person":{"type":"object","properties":{"name":{"type":"string"},"title":{"type":"string"}}},"person_phone":{"type":"string"},"people_named":{"type":"integer"},"tools":{"type":"array"},"signals":{"type":"array"},"linkedin":{"type":"string"},"about":{"type":"string"},"size_estimate":{"type":"object","additionalProperties":true},"state":{"type":"string"},"city":{"type":"string"},"us_how":{"type":"string"},"company":{"type":"string"},"why":{"type":"string"},"credits":{"type":"integer"},"repeat":{"type":"boolean"},"looked_up_at":{"type":"string"},"balance":{"type":"integer"}}}},"created_at":{"type":"string"},"finished_at":{"type":"string"}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"leads"}},"/describe":{"post":{"summary":"Turn a sentence into the finder's filters","operationId":"post_describe","parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"leads","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"text":{"type":"string"}},"required":["text"]}}}}}},"/campaigns/{campaign_id}/find":{"post":{"summary":"Find businesses for a draft campaign","operationId":"post_campaigns_campaign_id_find","parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"The campaign as the Cold email page shows it: id, name, state, steps, step_list, senders, writer, guide, signer, pitch, options, ab, people (its businesses), checks, can_launch, fingerprint, credits_estimate, rates, sent, by_status and more."}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"leads","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"niche":{"type":"string"},"area":{"type":"string"},"count":{"type":"integer"},"who":{"type":"string"},"uses":{"type":"array"},"not_uses":{"type":"array"},"signals":{"type":"array"},"min_team":{"type":"integer"},"keywords":{"type":"array","items":{"type":"string"},"maxItems":5},"no_chains":{"type":"boolean"},"source":{"enum":["","online","people"]}}}}}}}},"/campaigns/{campaign_id}/found":{"get":{"summary":"What a search found","operationId":"get_campaigns_campaign_id_found","parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"integer"}},{"name":"status","in":"query","schema":{"type":"string"},"description":"preview (found, not kept yet), active, …"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"finding":{"type":"object","additionalProperties":true},"data":{"type":"array","items":{"type":"object","properties":{"email":{"type":"string"},"first_name":{"type":"string"},"company":{"type":"string"},"website":{"type":"string"},"city":{"type":"string"},"state":{"type":"string"},"check":{"type":"string"},"first_line":{"type":"string"},"status":{"type":"string"},"detail":{"type":"string"},"sender":{"type":"string"},"next_due":{"type":"string"},"last_sent_at":{"type":"string"},"full_name":{"type":"string"},"title":{"type":"string"},"found":{"type":"string"},"linkedin":{"type":"string"},"about":{"type":"string"},"variant":{"type":"string"},"write_problem":{"type":"string"},"written_at":{"type":"string"},"phone":{"type":"string"},"person_phone":{"type":"string"},"crm":{"type":"string"},"id":{"type":"integer"},"step_done":{"type":"integer"},"contact_id":{"type":"integer"},"credits":{"type":"integer"},"emails":{"type":"array"},"tools":{"type":"array"},"signals":{"type":"array"},"confirmed":{"type":"boolean"},"has_person_phone":{"type":"boolean"},"company_data":{"type":"object","additionalProperties":true}}}}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"leads"}},"/campaigns/{campaign_id}/keep":{"post":{"summary":"Keep found businesses (free)","operationId":"post_campaigns_campaign_id_keep","parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"campaign":{"type":"object","additionalProperties":true,"description":"The campaign as the Cold email page shows it: id, name, state, steps, step_list, senders, writer, guide, signer, pitch, options, ab, people (its businesses), checks, can_launch, fingerprint, credits_estimate, rates, sent, by_status and more."}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"leads","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"integer"}},"all":{"type":"boolean"}}}}}}}},"/campaigns/{campaign_id}/discard":{"post":{"summary":"Pass on found businesses","operationId":"post_campaigns_campaign_id_discard","parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"campaign":{"type":"object","additionalProperties":true,"description":"The campaign as the Cold email page shows it: id, name, state, steps, step_list, senders, writer, guide, signer, pitch, options, ab, people (its businesses), checks, can_launch, fingerprint, credits_estimate, rates, sent, by_status and more."}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"leads","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"integer"}},"all":{"type":"boolean"}}}}}}}},"/campaigns":{"get":{"summary":"List campaigns, with what this business can send through","operationId":"get_campaigns","parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"enabled":{"type":"boolean"},"off":{"type":"string"},"domain":{"type":"object","additionalProperties":true},"sending":{"type":"object","additionalProperties":true},"caps":{"type":"object","additionalProperties":true},"campaigns":{"type":"array"}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"campaigns"},"post":{"summary":"Make a draft campaign","operationId":"post_campaigns","parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"The campaign as the Cold email page shows it: id, name, state, steps, step_list, senders, writer, guide, signer, pitch, options, ab, people (its businesses), checks, can_launch, fingerprint, credits_estimate, rates, sent, by_status and more."}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"campaigns","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string"},"pitch":{"type":"string"},"steps":{"type":"array","maxItems":6,"items":{"type":"object","properties":{"subject":{"type":"string"},"body":{"type":"string"},"wait_days":{"type":"integer","minimum":1,"maximum":30},"subject_b":{"type":"string"},"body_b":{"type":"string"},"subject_c":{"type":"string"},"body_c":{"type":"string"},"subject_d":{"type":"string"},"body_d":{"type":"string"}}}},"senders":{"type":"array","items":{"type":"string"}},"writer":{"enum":["otto","words"]},"guide":{"type":"string"},"signer":{"type":"string"},"ab":{"type":"object","properties":{"on":{"type":"boolean"},"count":{"type":"integer","minimum":2,"maximum":4},"auto":{"type":"boolean"},"guide_b":{"type":"string"},"guide_c":{"type":"string"},"guide_d":{"type":"string"}}},"options":{"type":"object","properties":{"schedule":{"type":"object","properties":{"days":{"type":"array","items":{"type":"integer","minimum":0,"maximum":6}},"start":{"type":"integer"},"end":{"type":"integer"}}},"stop_company":{"type":"boolean"},"daily_cap":{"type":"integer"},"start_on":{"type":"string","description":"YYYY-MM-DD"}}}}}}}}}},"/campaigns/{campaign_id}":{"get":{"summary":"Read a campaign","operationId":"get_campaigns_campaign_id","parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"The campaign as the Cold email page shows it: id, name, state, steps, step_list, senders, writer, guide, signer, pitch, options, ab, people (its businesses), checks, can_launch, fingerprint, credits_estimate, rates, sent, by_status and more."}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"campaigns"},"patch":{"summary":"Change a draft campaign","operationId":"patch_campaigns_campaign_id","parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"The campaign as the Cold email page shows it: id, name, state, steps, step_list, senders, writer, guide, signer, pitch, options, ab, people (its businesses), checks, can_launch, fingerprint, credits_estimate, rates, sent, by_status and more."}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"campaigns","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string"},"pitch":{"type":"string"},"steps":{"type":"array","maxItems":6,"items":{"type":"object","properties":{"subject":{"type":"string"},"body":{"type":"string"},"wait_days":{"type":"integer","minimum":1,"maximum":30},"subject_b":{"type":"string"},"body_b":{"type":"string"},"subject_c":{"type":"string"},"body_c":{"type":"string"},"subject_d":{"type":"string"},"body_d":{"type":"string"}}}},"senders":{"type":"array","items":{"type":"string"}},"writer":{"enum":["otto","words"]},"guide":{"type":"string"},"signer":{"type":"string"},"ab":{"type":"object","properties":{"on":{"type":"boolean"},"count":{"type":"integer","minimum":2,"maximum":4},"auto":{"type":"boolean"},"guide_b":{"type":"string"},"guide_c":{"type":"string"},"guide_d":{"type":"string"}}},"options":{"type":"object","properties":{"schedule":{"type":"object","properties":{"days":{"type":"array","items":{"type":"integer","minimum":0,"maximum":6}},"start":{"type":"integer"},"end":{"type":"integer"}}},"stop_company":{"type":"boolean"},"daily_cap":{"type":"integer"},"start_on":{"type":"string","description":"YYYY-MM-DD"}}}}}}}}}},"/campaigns/{campaign_id}/import":{"post":{"summary":"Add your own list as CSV","operationId":"post_campaigns_campaign_id_import","parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"added":{"type":"integer"},"duplicates":{"type":"integer"},"refused":{"type":"array"},"looking":{"type":"integer"},"stopped":{"type":"string"},"campaign":{"type":"object","additionalProperties":true,"description":"The campaign as the Cold email page shows it: id, name, state, steps, step_list, senders, writer, guide, signer, pitch, options, ab, people (its businesses), checks, can_launch, fingerprint, credits_estimate, rates, sent, by_status and more."}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"campaigns","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"csv":{"type":"string"},"default_state":{"type":"string"}},"required":["csv"]}}}}}},"/campaigns/{campaign_id}/write":{"post":{"summary":"Have Otto write each business its own emails","operationId":"post_campaigns_campaign_id_write","parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"The campaign as the Cold email page shows it: id, name, state, steps, step_list, senders, writer, guide, signer, pitch, options, ab, people (its businesses), checks, can_launch, fingerprint, credits_estimate, rates, sent, by_status and more."}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"campaigns","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"ids":{"type":"array","items":{"type":"integer"}}}}}}}}},"/campaigns/{campaign_id}/start":{"post":{"summary":"Ask to start: puts the one approval in Reviews (never sends)","operationId":"post_campaigns_campaign_id_start","parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"The campaign as the Cold email page shows it: id, name, state, steps, step_list, senders, writer, guide, signer, pitch, options, ab, people (its businesses), checks, can_launch, fingerprint, credits_estimate, rates, sent, by_status and more."}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"campaigns","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"fingerprint":{"type":"string"}},"required":["fingerprint"]}}}}}},"/campaigns/{campaign_id}/{verb}":{"post":{"summary":"Pause, resume or cancel a running campaign","operationId":"post_campaigns_campaign_id_verb","parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"integer"}},{"name":"verb","in":"path","required":true,"schema":{"enum":["pause","resume","cancel"]}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"The campaign as the Cold email page shows it: id, name, state, steps, step_list, senders, writer, guide, signer, pitch, options, ab, people (its businesses), checks, can_launch, fingerprint, credits_estimate, rates, sent, by_status and more."}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"campaigns"}},"/campaigns/{campaign_id}/prospects/{prospect_id}":{"patch":{"summary":"Change one business in a draft campaign","operationId":"patch_campaigns_campaign_id_prospects_prospect_id","parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"integer"}},{"name":"prospect_id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"email":{"type":"string"},"first_name":{"type":"string"},"company":{"type":"string"},"website":{"type":"string"},"city":{"type":"string"},"state":{"type":"string"},"check":{"type":"string"},"first_line":{"type":"string"},"status":{"type":"string"},"detail":{"type":"string"},"sender":{"type":"string"},"next_due":{"type":"string"},"last_sent_at":{"type":"string"},"full_name":{"type":"string"},"title":{"type":"string"},"found":{"type":"string"},"linkedin":{"type":"string"},"about":{"type":"string"},"variant":{"type":"string"},"write_problem":{"type":"string"},"written_at":{"type":"string"},"phone":{"type":"string"},"person_phone":{"type":"string"},"crm":{"type":"string"},"id":{"type":"integer"},"step_done":{"type":"integer"},"contact_id":{"type":"integer"},"credits":{"type":"integer"},"emails":{"type":"array"},"tools":{"type":"array"},"signals":{"type":"array"},"confirmed":{"type":"boolean"},"has_person_phone":{"type":"boolean"},"company_data":{"type":"object","additionalProperties":true}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"campaigns","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"first_line":{"type":"string"},"emails":{"type":"array"},"check_again":{"type":"boolean"}}}}}}},"delete":{"summary":"Take one business out of a draft campaign","operationId":"delete_campaigns_campaign_id_prospects_prospect_id","parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"integer"}},{"name":"prospect_id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"campaigns"}},"/campaigns/{campaign_id}/export.csv":{"get":{"summary":"Businesses that may still be written to, as CSV","operationId":"get_campaigns_campaign_id_export_csv","parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"text/csv":{"schema":{"type":"string","contentMediaType":"text/csv"}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"campaigns"}},"/do-not-contact":{"get":{"summary":"Settings → Do not contact","operationId":"get_do_not_contact","parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"entries":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"value":{"type":"string"},"reason":{"type":"string"},"created_at":{"type":"string"}}}},"added":{"type":"integer"}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"campaigns"},"post":{"summary":"Add addresses or domains to Do not contact","operationId":"post_do_not_contact","parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"entries":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"value":{"type":"string"},"reason":{"type":"string"},"created_at":{"type":"string"}}}},"added":{"type":"integer"}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"campaigns","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"values":{"type":"string","description":"Separated by spaces, commas or new lines; up to 500."}},"required":["values"]}}}}}},"/do-not-contact/{entry_id}":{"delete":{"summary":"Remove one added by hand","operationId":"delete_do_not_contact_entry_id","parameters":[{"name":"entry_id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"entries":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"value":{"type":"string"},"reason":{"type":"string"},"created_at":{"type":"string"}}}},"added":{"type":"integer"}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"campaigns"}},"/mailboxes":{"get":{"summary":"Sending addresses: limits, warm-up, rates","operationId":"get_mailboxes","parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"mailboxes":{"type":"array"},"placement":{"type":"object","additionalProperties":true},"warmup":{"type":"object","additionalProperties":true}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"campaigns"}},"/mailboxes/accounts":{"get":{"summary":"Connected mailboxes and whether each works (never a password)","operationId":"get_mailboxes_accounts","parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"accounts":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"address":{"type":"string"},"kind":{"type":"string"},"status":{"type":"string"},"problem":{"type":"string"},"connected_at":{"type":"string"},"checked_at":{"type":"string"},"polled_at":{"type":"string"}}}},"ses":{"type":"boolean"},"microsoft":{"type":"object","additionalProperties":true}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"campaigns"}},"/domains":{"get":{"summary":"Sending domains and the DNS records each needs","operationId":"get_domains","parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"main":{"type":"object","additionalProperties":true},"most":{"type":"integer"},"buying":{"type":"boolean"},"buying_note":{"type":"string"},"domains":{"type":"array"}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"campaigns"}},"/replies":{"get":{"summary":"Sorted replies with Otto's drafted answers","operationId":"get_replies","parameters":[{"name":"label","in":"query","schema":{"type":"string"}},{"name":"state","in":"query","schema":{"enum":["open","answered","done","all"],"default":"open"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"replies":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"label":{"type":"string"},"label_text":{"type":"string"},"sorted_by":{"type":"string"},"state":{"type":"string"},"draft":{"type":"string"},"answer":{"type":"string"},"problem":{"type":"string"},"created_at":{"type":"string"},"answered_at":{"type":"string"},"review":{"type":"object","additionalProperties":true},"campaign":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string"}}},"person":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string"},"title":{"type":"string"},"company":{"type":"string"},"email":{"type":"string"},"contact_id":{"type":"integer"},"crm":{"type":"string"}}},"subject":{"type":"string"},"text":{"type":"string"},"auto":{"type":"boolean"},"send_at":{"type":"string"},"follow_on":{"type":"string"},"outcome":{"type":"string"}}}},"open":{"type":"object","additionalProperties":true},"labels":{"type":"object","additionalProperties":true},"rule":{"type":"string"},"receiving":{"type":"boolean"},"autopilot":{"type":"object","additionalProperties":true}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"replies"}},"/replies/{reply_id}/answer":{"post":{"summary":"Answer a reply (waits in Reviews unless set to Auto)","operationId":"post_replies_reply_id_answer","parameters":[{"name":"reply_id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"done":{"type":"string"},"reply":{"type":"object","properties":{"id":{"type":"integer"},"label":{"type":"string"},"label_text":{"type":"string"},"sorted_by":{"type":"string"},"state":{"type":"string"},"draft":{"type":"string"},"answer":{"type":"string"},"problem":{"type":"string"},"created_at":{"type":"string"},"answered_at":{"type":"string"},"review":{"type":"object","additionalProperties":true},"campaign":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string"}}},"person":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string"},"title":{"type":"string"},"company":{"type":"string"},"email":{"type":"string"},"contact_id":{"type":"integer"},"crm":{"type":"string"}}},"subject":{"type":"string"},"text":{"type":"string"},"auto":{"type":"boolean"},"send_at":{"type":"string"},"follow_on":{"type":"string"},"outcome":{"type":"string"}}}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"replies","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"body":{"type":"string"}},"required":["body"]}}}}}},"/extension/campaigns":{"get":{"summary":"The Chrome extension: draft campaigns and credits","operationId":"get_extension_campaigns","parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"business":{"type":"string"},"enabled":{"type":"boolean"},"off":{"type":"string"},"balance":{"type":"integer"},"campaigns":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string"}}}}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"leads"}},"/extension/look":{"post":{"summary":"The Chrome extension: who runs a website, address hidden (free)","operationId":"post_extension_look","parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"domain":{"type":"string"},"company":{"type":"string"},"found":{"type":"boolean"},"why":{"type":"string"},"email":{"type":"string","description":"masked"},"how":{"type":"string"},"confirmed":{"type":"boolean"},"person":{"type":"object","properties":{"name":{"type":"string"},"title":{"type":"string"}}},"has_phone":{"type":"boolean"},"signals":{"type":"array"},"tools":{"type":"array"},"state":{"type":"string"},"city":{"type":"string"},"us":{"type":"boolean"},"cost":{"type":"integer"},"ticket":{"type":"string","description":"sealed; send it to /extension/add within a day"}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"leads","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"website":{"type":"string"}},"required":["website"]}}}}}},"/extension/add":{"post":{"summary":"The Chrome extension: put a look into a draft campaign, as found (free)","operationId":"post_extension_add","parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"prospect":{"type":"object","properties":{"email":{"type":"string"},"first_name":{"type":"string"},"company":{"type":"string"},"website":{"type":"string"},"city":{"type":"string"},"state":{"type":"string"},"check":{"type":"string"},"first_line":{"type":"string"},"status":{"type":"string"},"detail":{"type":"string"},"sender":{"type":"string"},"next_due":{"type":"string"},"last_sent_at":{"type":"string"},"full_name":{"type":"string"},"title":{"type":"string"},"found":{"type":"string"},"linkedin":{"type":"string"},"about":{"type":"string"},"variant":{"type":"string"},"write_problem":{"type":"string"},"written_at":{"type":"string"},"phone":{"type":"string"},"person_phone":{"type":"string"},"crm":{"type":"string"},"id":{"type":"integer"},"step_done":{"type":"integer"},"contact_id":{"type":"integer"},"credits":{"type":"integer"},"emails":{"type":"array"},"tools":{"type":"array"},"signals":{"type":"array"},"confirmed":{"type":"boolean"},"has_person_phone":{"type":"boolean"},"company_data":{"type":"object","additionalProperties":true}}},"campaign":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string"}}},"cost":{"type":"integer"},"balance":{"type":"integer"}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"leads","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"ticket":{"type":"string"},"campaign_id":{"type":"integer"}},"required":["ticket","campaign_id"]}}}}}},"/hooks":{"get":{"summary":"Webhooks this key added","operationId":"get_hooks","parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"url":{"type":"string"},"events":{"type":"array"},"on":{"type":"boolean"},"failures":{"type":"integer"},"last_status":{"type":"string"},"last_at":{"type":"string"},"created_at":{"type":"string"},"by_key":{"type":"boolean"}}}},"events":{"type":"object","additionalProperties":true}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"any"},"post":{"summary":"Add a webhook (needs the scope of each event)","operationId":"post_hooks","parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"integer"},"url":{"type":"string"},"events":{"type":"array"},"on":{"type":"boolean"},"failures":{"type":"integer"},"last_status":{"type":"string"},"last_at":{"type":"string"},"created_at":{"type":"string"},"by_key":{"type":"boolean"},"secret":{"type":"string"}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"by event","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"url":{"type":"string"},"target_url":{"type":"string"},"event":{"enum":["reply.received","reply.sorted","lead.kept","campaign.started","campaign.finished"]},"events":{"type":"array","items":{"enum":["reply.received","reply.sorted","lead.kept","campaign.started","campaign.finished"]}}}}}}}}},"/hooks/{hook_id}":{"delete":{"summary":"Remove a webhook this key added","operationId":"delete_hooks_hook_id","parameters":[{"name":"hook_id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"removed":{"type":"integer"}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"any"}},"/hooks/samples/{event}":{"get":{"summary":"The last few bodies of an event, or one marked sample","operationId":"get_hooks_samples_event","parameters":[{"name":"event","in":"path","required":true,"schema":{"enum":["reply.received","reply.sorted","lead.kept","campaign.started","campaign.finished"]}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array"}}}}}},"401":{"description":"No key, or a revoked one","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"403":{"description":"The key lacks this scope, or the feature is off for the business","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"404":{"description":"Not this business's, or not here any more","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"409":{"description":"Not now (a draft-only change, a campaign not ready, …)","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"429":{"description":"60 requests a minute per key, or a daily limit","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}},"400":{"description":"The request is missing or wrong","content":{"application/json":{"schema":{"type":"object","properties":{"detail":{"type":"string"}}}}}}},"x-otto-scope":"by event"}},"/openapi.json":{"get":{"summary":"This document","operationId":"get_openapi","security":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}}}}}}}