{"openapi":"3.1.0","info":{"title":"Moja API","description":"Moja API for campaigns, targets, RTBs, routing plans, buyers, publishers, transaction reporting, and inbound/outbound RTB analytics. Authenticate with `X-API-Key` or `Authorization: Bearer <api_key>`.","version":"1.0.0"},"paths":{"/api/v1/campaigns":{"get":{"tags":["Campaigns"],"summary":"List campaigns","operationId":"list_campaigns_campaigns_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"post":{"tags":["Campaigns"],"summary":"Create a campaign","operationId":"create_campaign_campaigns_post","parameters":[{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/campaigns/{campaign_id}":{"get":{"tags":["Campaigns"],"summary":"Get a campaign","operationId":"get_campaign_campaigns__campaign_id__get","parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"string","title":"Campaign Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"patch":{"tags":["Campaigns"],"summary":"Patch a campaign","operationId":"patch_campaign_campaigns__campaign_id__patch","parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"string","title":"Campaign Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignPatch"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CampaignResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/campaigns/{campaign_id}/pausable-entities":{"get":{"tags":["Campaigns"],"summary":"List targets and RTB formulas reachable from a campaign that can be paused","operationId":"list_pausable_entities_for_campaign_campaigns__campaign_id__pausable_entities_get","parameters":[{"name":"campaign_id","in":"path","required":true,"schema":{"type":"string","title":"Campaign Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PausableEntitiesResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/call-flows":{"get":{"tags":["Call Flows"],"summary":"List Call Flows","operationId":"list_call_flows_call_flows_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CallFlowListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"post":{"tags":["Call Flows"],"summary":"Create Call Flow","operationId":"create_call_flow_call_flows_post","parameters":[{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CallFlowCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CallFlowResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/call-flows/{id_or_external_id}":{"get":{"tags":["Call Flows"],"summary":"Get Call Flow","operationId":"get_call_flow_call_flows__id_or_external_id__get","parameters":[{"name":"id_or_external_id","in":"path","required":true,"schema":{"type":"string","title":"Id Or External Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CallFlowResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"patch":{"tags":["Call Flows"],"summary":"Patch Call Flow","operationId":"patch_call_flow_call_flows__id_or_external_id__patch","parameters":[{"name":"id_or_external_id","in":"path","required":true,"schema":{"type":"string","title":"Id Or External Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CallFlowPatch"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CallFlowResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"delete":{"tags":["Call Flows"],"summary":"Delete Call Flow","operationId":"delete_call_flow_call_flows__id_or_external_id__delete","parameters":[{"name":"id_or_external_id","in":"path","required":true,"schema":{"type":"string","title":"Id Or External Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/call-flows/{id_or_external_id}/media-bindings":{"patch":{"tags":["Call Flows"],"summary":"Bind Call Flow Media","operationId":"bind_call_flow_media_call_flows__id_or_external_id__media_bindings_patch","parameters":[{"name":"id_or_external_id","in":"path","required":true,"schema":{"type":"string","title":"Id Or External Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CallFlowMediaPatch"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CallFlowResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/custom-tags":{"get":{"tags":["Custom Tags"],"summary":"List custom tags","operationId":"list_custom_tags_custom_tags_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomTagListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"post":{"tags":["Custom Tags"],"summary":"Create a custom tag","operationId":"create_custom_tag_custom_tags_post","parameters":[{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomTagCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomTagResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/custom-tags/{custom_tag_id}":{"get":{"tags":["Custom Tags"],"summary":"Get a custom tag","operationId":"get_custom_tag_custom_tags__custom_tag_id__get","parameters":[{"name":"custom_tag_id","in":"path","required":true,"schema":{"type":"string","title":"Custom Tag Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomTagResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"patch":{"tags":["Custom Tags"],"summary":"Patch a custom tag","operationId":"patch_custom_tag_custom_tags__custom_tag_id__patch","parameters":[{"name":"custom_tag_id","in":"path","required":true,"schema":{"type":"string","title":"Custom Tag Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomTagPatch"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomTagResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"delete":{"tags":["Custom Tags"],"summary":"Delete a custom tag","operationId":"delete_custom_tag_custom_tags__custom_tag_id__delete","parameters":[{"name":"custom_tag_id","in":"path","required":true,"schema":{"type":"string","title":"Custom Tag Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/pause":{"post":{"tags":["Pause"],"summary":"Pause multiple targets or RTB formulas","operationId":"bulk_pause_pause_post","parameters":[{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkPauseRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkPauseResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/resume":{"post":{"tags":["Pause"],"summary":"Resume multiple targets or RTB formulas","operationId":"bulk_resume_resume_post","parameters":[{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkResumeRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkResumeResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/targets":{"get":{"tags":["Targets"],"summary":"List targets","operationId":"list_targets_targets_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TargetListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"post":{"tags":["Targets"],"summary":"Create a target","operationId":"create_target_targets_post","parameters":[{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TargetCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TargetResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/targets/{target_id}":{"get":{"tags":["Targets"],"summary":"Get a target","operationId":"get_target_targets__target_id__get","parameters":[{"name":"target_id","in":"path","required":true,"schema":{"type":"string","title":"Target Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TargetResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"patch":{"tags":["Targets"],"summary":"Patch a target","operationId":"patch_target_targets__target_id__patch","parameters":[{"name":"target_id","in":"path","required":true,"schema":{"type":"string","title":"Target Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TargetPatch"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TargetResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/targets/{target_id}/pause":{"post":{"tags":["Targets"],"summary":"Pause a target","operationId":"pause_target_targets__target_id__pause_post","parameters":[{"name":"target_id","in":"path","required":true,"schema":{"type":"string","title":"Target Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PauseRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TargetResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"delete":{"tags":["Targets"],"summary":"Resume a target","operationId":"resume_target_targets__target_id__pause_delete","parameters":[{"name":"target_id","in":"path","required":true,"schema":{"type":"string","title":"Target Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TargetResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/rtbs":{"get":{"tags":["RTBs"],"summary":"List RTB formulas","operationId":"list_rtbs_rtbs_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RTBListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"post":{"tags":["RTBs"],"summary":"Create an RTB formula","operationId":"create_rtb_rtbs_post","parameters":[{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RTBCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RTBResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/rtbs/{rtb_id}":{"get":{"tags":["RTBs"],"summary":"Get an RTB formula","operationId":"get_rtb_rtbs__rtb_id__get","parameters":[{"name":"rtb_id","in":"path","required":true,"schema":{"type":"string","title":"Rtb Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RTBResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"patch":{"tags":["RTBs"],"summary":"Patch an RTB formula","operationId":"patch_rtb_rtbs__rtb_id__patch","parameters":[{"name":"rtb_id","in":"path","required":true,"schema":{"type":"string","title":"Rtb Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RTBPatch"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RTBResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/rtbs/{rtb_id}/pause":{"post":{"tags":["RTBs"],"summary":"Pause an RTB formula","operationId":"pause_rtb_rtbs__rtb_id__pause_post","parameters":[{"name":"rtb_id","in":"path","required":true,"schema":{"type":"string","title":"Rtb Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PauseRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RTBResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"delete":{"tags":["RTBs"],"summary":"Resume an RTB formula","operationId":"resume_rtb_rtbs__rtb_id__pause_delete","parameters":[{"name":"rtb_id","in":"path","required":true,"schema":{"type":"string","title":"Rtb Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RTBResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/rtb-groups":{"get":{"tags":["RTB Groups"],"summary":"List RTB groups","operationId":"list_rtb_groups_rtb_groups_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RTBGroupListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"post":{"tags":["RTB Groups"],"summary":"Create an RTB group","operationId":"create_rtb_group_rtb_groups_post","parameters":[{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RTBGroupCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RTBGroupResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/rtb-groups/{rtb_group_id}":{"get":{"tags":["RTB Groups"],"summary":"Get an RTB group","operationId":"get_rtb_group_rtb_groups__rtb_group_id__get","parameters":[{"name":"rtb_group_id","in":"path","required":true,"schema":{"type":"string","title":"Rtb Group Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RTBGroupResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"patch":{"tags":["RTB Groups"],"summary":"Patch an RTB group","operationId":"patch_rtb_group_rtb_groups__rtb_group_id__patch","parameters":[{"name":"rtb_group_id","in":"path","required":true,"schema":{"type":"string","title":"Rtb Group Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RTBGroupPatch"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RTBGroupResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"delete":{"tags":["RTB Groups"],"summary":"Delete an RTB group","operationId":"delete_rtb_group_rtb_groups__rtb_group_id__delete","parameters":[{"name":"rtb_group_id","in":"path","required":true,"schema":{"type":"string","title":"Rtb Group Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/routing-plans":{"get":{"tags":["Routing Plans"],"summary":"List routing plans","operationId":"list_routing_plans_routing_plans_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoutingPlanListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"post":{"tags":["Routing Plans"],"summary":"Create a routing plan","operationId":"create_routing_plan_routing_plans_post","parameters":[{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoutingPlanCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoutingPlanResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/routing-plans/{routing_plan_id}":{"get":{"tags":["Routing Plans"],"summary":"Get a routing plan","operationId":"get_routing_plan_routing_plans__routing_plan_id__get","parameters":[{"name":"routing_plan_id","in":"path","required":true,"schema":{"type":"string","title":"Routing Plan Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoutingPlanResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"patch":{"tags":["Routing Plans"],"summary":"Patch a routing plan","operationId":"patch_routing_plan_routing_plans__routing_plan_id__patch","parameters":[{"name":"routing_plan_id","in":"path","required":true,"schema":{"type":"string","title":"Routing Plan Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoutingPlanPatch"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoutingPlanResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/routing-plans/{routing_plan_id}/pausable-entities":{"get":{"tags":["Routing Plans"],"summary":"List targets and RTB formulas in a routing plan that can be paused","operationId":"list_pausable_entities_for_routing_plan_routing_plans__routing_plan_id__pausable_entities_get","parameters":[{"name":"routing_plan_id","in":"path","required":true,"schema":{"type":"string","title":"Routing Plan Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PausableEntitiesResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/buyers":{"get":{"tags":["Buyers"],"summary":"List buyers","operationId":"list_buyers_buyers_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BuyerListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"post":{"tags":["Buyers"],"summary":"Create a buyer","operationId":"create_buyer_buyers_post","parameters":[{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BuyerCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BuyerResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/buyers/{buyer_id}":{"get":{"tags":["Buyers"],"summary":"Get a buyer","operationId":"get_buyer_buyers__buyer_id__get","parameters":[{"name":"buyer_id","in":"path","required":true,"schema":{"type":"string","title":"Buyer Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BuyerResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"patch":{"tags":["Buyers"],"summary":"Patch a buyer","operationId":"patch_buyer_buyers__buyer_id__patch","parameters":[{"name":"buyer_id","in":"path","required":true,"schema":{"type":"string","title":"Buyer Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BuyerPatch"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BuyerResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"delete":{"tags":["Buyers"],"summary":"Delete a buyer","operationId":"delete_buyer_buyers__buyer_id__delete","parameters":[{"name":"buyer_id","in":"path","required":true,"schema":{"type":"string","title":"Buyer Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/publishers":{"get":{"tags":["Publishers"],"summary":"List publishers","operationId":"list_publishers_publishers_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublisherListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"post":{"tags":["Publishers"],"summary":"Create a publisher","operationId":"create_publisher_publishers_post","parameters":[{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublisherCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublisherResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/publishers/{publisher_id}":{"get":{"tags":["Publishers"],"summary":"Get a publisher","operationId":"get_publisher_publishers__publisher_id__get","parameters":[{"name":"publisher_id","in":"path","required":true,"schema":{"type":"string","title":"Publisher Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublisherResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"patch":{"tags":["Publishers"],"summary":"Patch a publisher","operationId":"patch_publisher_publishers__publisher_id__patch","parameters":[{"name":"publisher_id","in":"path","required":true,"schema":{"type":"string","title":"Publisher Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublisherPatch"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublisherResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"delete":{"tags":["Publishers"],"summary":"Delete a publisher","operationId":"delete_publisher_publishers__publisher_id__delete","parameters":[{"name":"publisher_id","in":"path","required":true,"schema":{"type":"string","title":"Publisher Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/numbers":{"get":{"tags":["Numbers"],"summary":"List numbers","operationId":"list_numbers_numbers_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"campaign_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Campaign Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NumberListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/numbers/buy":{"post":{"tags":["Numbers"],"summary":"Buy a number","description":"Buy one or more numbers through the configured phone-number provider (max 10 per order). Provide `prefix` for a local area code or toll-free NPA; set `toll_free=true` for toll-free (defaults to 800 if prefix omitted). Use `quantity` for multiple numbers in one order. The response includes purchased numbers under `numbers` (and `number` when quantity is 1).","operationId":"buy_number_numbers_buy_post","parameters":[{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NumberBuyRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/numbers/{number_id}":{"get":{"tags":["Numbers"],"summary":"Get a number","operationId":"get_number_numbers__number_id__get","parameters":[{"name":"number_id","in":"path","required":true,"schema":{"type":"string","title":"Number Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NumberResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/incoming-webhooks":{"get":{"tags":["Incoming Webhooks"],"summary":"List incoming webhook configurations","operationId":"list_incoming_webhooks_incoming_webhooks_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IncomingWebhookListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"post":{"tags":["Incoming Webhooks"],"summary":"Create an incoming webhook configuration","operationId":"create_incoming_webhook_incoming_webhooks_post","parameters":[{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IncomingWebhookCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IncomingWebhookResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/incoming-webhooks/{webhook_id}":{"get":{"tags":["Incoming Webhooks"],"summary":"Get an incoming webhook configuration","operationId":"get_incoming_webhook_incoming_webhooks__webhook_id__get","parameters":[{"name":"webhook_id","in":"path","required":true,"schema":{"type":"string","title":"Webhook Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IncomingWebhookResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"patch":{"tags":["Incoming Webhooks"],"summary":"Patch an incoming webhook configuration","operationId":"patch_incoming_webhook_incoming_webhooks__webhook_id__patch","parameters":[{"name":"webhook_id","in":"path","required":true,"schema":{"type":"string","title":"Webhook Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IncomingWebhookPatch"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IncomingWebhookResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"delete":{"tags":["Incoming Webhooks"],"summary":"Delete an incoming webhook configuration","operationId":"delete_incoming_webhook_incoming_webhooks__webhook_id__delete","parameters":[{"name":"webhook_id","in":"path","required":true,"schema":{"type":"string","title":"Webhook Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/outgoing-webhooks":{"get":{"tags":["Outgoing Webhooks"],"summary":"List outgoing webhook configurations","operationId":"list_outgoing_webhooks_outgoing_webhooks_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutgoingWebhookListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"post":{"tags":["Outgoing Webhooks"],"summary":"Create an outgoing webhook configuration","operationId":"create_outgoing_webhook_outgoing_webhooks_post","parameters":[{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutgoingWebhookCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutgoingWebhookResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/outgoing-webhooks/{webhook_id}":{"get":{"tags":["Outgoing Webhooks"],"summary":"Get an outgoing webhook configuration","operationId":"get_outgoing_webhook_outgoing_webhooks__webhook_id__get","parameters":[{"name":"webhook_id","in":"path","required":true,"schema":{"type":"string","title":"Webhook Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutgoingWebhookResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"patch":{"tags":["Outgoing Webhooks"],"summary":"Patch an outgoing webhook configuration","operationId":"patch_outgoing_webhook_outgoing_webhooks__webhook_id__patch","parameters":[{"name":"webhook_id","in":"path","required":true,"schema":{"type":"string","title":"Webhook Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutgoingWebhookPatch"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutgoingWebhookResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"delete":{"tags":["Outgoing Webhooks"],"summary":"Delete an outgoing webhook configuration","operationId":"delete_outgoing_webhook_outgoing_webhooks__webhook_id__delete","parameters":[{"name":"webhook_id","in":"path","required":true,"schema":{"type":"string","title":"Webhook Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/audit-logs":{"get":{"tags":["Audit Logs"],"summary":"List audit log entries","operationId":"list_audit_logs_audit_logs_get","parameters":[{"name":"entity_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Partial match on entity_type (SQL LIKE %value%)","title":"Entity Type"},"description":"Partial match on entity_type (SQL LIKE %value%)"},{"name":"entity_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by entity id","title":"Entity Id"},"description":"Filter by entity id"},{"name":"user_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by acting user id","title":"User Id"},"description":"Filter by acting user id"},{"name":"action","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"create | update | delete","title":"Action"},"description":"create | update | delete"},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Search in changes JSON, route, entity_type, user_email, user_id, entity_id, entity_name","title":"Q"},"description":"Search in changes JSON, route, entity_type, user_email, user_id, entity_id, entity_name"},{"name":"from","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"From"}},{"name":"to","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"To"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuditLogListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/audit-logs/field-changes":{"get":{"tags":["Audit Logs"],"summary":"List audit log field changes (flattened)","operationId":"list_audit_log_field_changes_audit_logs_field_changes_get","parameters":[{"name":"entity_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Partial match on entity_type (SQL LIKE %value%)","title":"Entity Type"},"description":"Partial match on entity_type (SQL LIKE %value%)"},{"name":"entity_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by entity id","title":"Entity Id"},"description":"Filter by entity id"},{"name":"user_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by acting user id","title":"User Id"},"description":"Filter by acting user id"},{"name":"action","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"create | update | delete","title":"Action"},"description":"create | update | delete"},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Search in changes JSON, route, entity_type, user_email, user_id, entity_id, entity_name","title":"Q"},"description":"Search in changes JSON, route, entity_type, user_email, user_id, entity_id, entity_name"},{"name":"from","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"From"}},{"name":"to","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"To"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuditLogFieldChangeListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/audit-logs/field-changes/export.csv":{"get":{"tags":["Audit Logs"],"summary":"Export flattened audit field changes as CSV","operationId":"export_audit_log_field_changes_csv_audit_logs_field_changes_export_csv_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100000,"minimum":1,"description":"Max field-change rows to export","default":20,"title":"Limit"},"description":"Max field-change rows to export"},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"entity_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Type"}},{"name":"entity_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Id"}},{"name":"user_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id"}},{"name":"action","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Action"}},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Search in changes JSON, route, entity_type, user_email, user_id, entity_id, entity_name","title":"Q"},"description":"Search in changes JSON, route, entity_type, user_email, user_id, entity_id, entity_name"},{"name":"from","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"From"}},{"name":"to","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"To"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/audit-logs/export.csv":{"get":{"tags":["Audit Logs"],"summary":"Export audit log as CSV","operationId":"export_audit_logs_csv_audit_logs_export_csv_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100000,"minimum":1,"description":"Max rows to export for the selected filters and date range","default":20,"title":"Limit"},"description":"Max rows to export for the selected filters and date range"},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"description":"Offset into filtered results; export matches list page","default":0,"title":"Offset"},"description":"Offset into filtered results; export matches list page"},{"name":"entity_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Type"}},{"name":"entity_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Id"}},{"name":"user_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id"}},{"name":"action","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Action"}},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Search in changes JSON, route, entity_type, user_email, user_id, entity_id, entity_name","title":"Q"},"description":"Search in changes JSON, route, entity_type, user_email, user_id, entity_id, entity_name"},{"name":"from","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"From"}},{"name":"to","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"To"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/audit-logs/{log_id}":{"get":{"tags":["Audit Logs"],"summary":"Get one audit log entry","operationId":"get_audit_log_audit_logs__log_id__get","parameters":[{"name":"log_id","in":"path","required":true,"schema":{"type":"string","title":"Log Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuditLogDetail"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/reporting/calls/query":{"post":{"tags":["Reporting"],"summary":"Call log","description":"Paginated call log rows for your organization. Returns the same columns as the in-app admin call log grid (excluding UI-only and default QAI-only fields), plus cost (computed USD carrier cost per row; zero for Moja Magic calls), cost_per_min (USD per billable minute, same numeric scale as cost), billable_minutes (per-call rounded minutes used for cost), caller city and state derived from the caller ZIP (zipCode) via the NPA/NXX reference table when available, sticky_caller (true when the call was routed via Duplicate Call Routing / Sticky Caller to the same buyer or destination as a prior call), plus a time-limited presigned recording_url when recordings are available. Pass `include_tags` with system and/or custom tag keys to attach a per-row `tags` map (e.g. original_state, original_zip_code, after_agent_state, after_agent_zip, or any custom tag).","operationId":"reporting_calls_query_reporting_calls_query_post","parameters":[{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportingCallsQueryRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportingCallsQueryResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/reporting/calls/summary":{"post":{"tags":["Reporting"],"summary":"Call summary","description":"Aggregated call metrics grouped by one dimension (campaign, publisher, buyer, routing_plan, caller_id, target_number, publisher_number, ivr_menu, route-to-target, or date, etc.). Admin cost excludes Moja Magic minutes.","operationId":"reporting_calls_summary_reporting_calls_summary_post","parameters":[{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportingCallsSummaryRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportingCallsSummaryResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/reporting/calls/payout/bulk-adjust":{"post":{"tags":["Reporting"],"summary":"Bulk adjust payouts","description":"Sets revenue_paid_out and/or publisher_paid_out to the same value(s) on each listed call log id for your organization. Provide at least one of revenue_paid_out or publisher_paid_out. Use ids returned by `POST /api/v1/reporting/calls/query`. `failed_call_log_ids` lists request ids that do not exist for your organization (no matching call log row). Repeating the same request is safe when amounts are unchanged (adjustment flags only update when a value differs).","operationId":"reporting_bulk_adjust_payouts_reporting_calls_payout_bulk_adjust_post","parameters":[{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportingBulkPayoutAdjustRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportingBulkPayoutAdjustResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"500":{"description":"Internal server error"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/reporting/calls/{call_id}/life":{"get":{"tags":["Reporting"],"summary":"Call life timeline","description":"Ordered life log events for a call id. Same payload as `GET /reporting/call-life/{call_id}` in the product API, authenticated with an organization API key.","operationId":"reporting_call_life_reporting_calls__call_id__life_get","parameters":[{"name":"call_id","in":"path","required":true,"schema":{"type":"string","title":"Call Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CallLifeResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"503":{"description":"Reporting data store unavailable or disabled"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/webhooks/incoming-requests":{"get":{"tags":["Webhooks"],"summary":"Incoming webhook request history","description":"Paginated incoming webhook deliveries for your organization. Same row shape as `GET /incoming_webhook_requests/get` in the product API, authenticated with an organization API key.","operationId":"list_incoming_webhook_requests_webhooks_incoming_requests_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start Date"}},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End Date"}},{"name":"incoming_webhook_config_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Incoming Webhook Config Id"}},{"name":"sort_direction","in":"query","required":false,"schema":{"enum":["asc","desc"],"type":"string","default":"desc","title":"Sort Direction"}},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Q"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IncomingWebhookRequestListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"503":{"description":"ClickHouse unavailable or disabled"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/webhooks/outgoing-requests":{"get":{"tags":["Webhooks"],"summary":"Outgoing webhook request history","description":"Paginated outgoing webhook deliveries for your organization. Same row shape as `GET /outgoing_webhook_requests/get` in the product API, authenticated with an organization API key.","operationId":"list_outgoing_webhook_requests_webhooks_outgoing_requests_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start Date"}},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End Date"}},{"name":"outgoing_webhook_config_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outgoing Webhook Config Id"}},{"name":"event_type_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Event Type Id"}},{"name":"sort_direction","in":"query","required":false,"schema":{"enum":["asc","desc"],"type":"string","default":"desc","title":"Sort Direction"}},{"name":"q","in":"query","required":false,"schema":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Q"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutgoingWebhookRequestListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"503":{"description":"ClickHouse unavailable or disabled"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/inbound-rtb":{"get":{"tags":["Inbound RTB"],"summary":"List inbound RTBs","operationId":"list_inbound_rtbs_inbound_rtb_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"campaign_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Campaign Id"}},{"name":"publisher_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publisher Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboundRtbListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"post":{"tags":["Inbound RTB"],"summary":"Create an inbound RTB","operationId":"create_inbound_rtb_inbound_rtb_post","parameters":[{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboundRtbCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboundRtbResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/inbound-rtb/summary/requests":{"get":{"tags":["Inbound RTB"],"summary":"Paginated inbound RTB summary with request params","operationId":"inbound_rtb_summary_requests_inbound_rtb_summary_requests_get","parameters":[{"name":"start_date","in":"query","required":true,"schema":{"type":"string","description":"Start of date range filter on irr.created_at.","title":"Start Date"},"description":"Start of date range filter on irr.created_at."},{"name":"end_date","in":"query","required":true,"schema":{"type":"string","description":"End of date range filter on irr.created_at.","title":"End Date"},"description":"End of date range filter on irr.created_at."},{"name":"campaign_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Campaign Id"}},{"name":"publisher_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publisher Id"}},{"name":"buyer_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Id"}},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Search request id, state, or caller id (substring).","title":"Search"},"description":"Search request id, state, or caller id (substring)."},{"name":"sort","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"One of: created_at, state, request_caller_id, processing_time_ms, duration, publisher_payout, campaign, publisher, allocation.","title":"Sort"},"description":"One of: created_at, state, request_caller_id, processing_time_ms, duration, publisher_payout, campaign, publisher, allocation."},{"name":"sort_direction","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"'asc' or 'desc'.","title":"Sort Direction"},"description":"'asc' or 'desc'."},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboundRtbSummaryRequestsListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/inbound-rtb/requests":{"get":{"tags":["Inbound RTB"],"summary":"Paginated inbound RTB request list","operationId":"inbound_rtb_requests_inbound_rtb_requests_get","parameters":[{"name":"start_date","in":"query","required":true,"schema":{"type":"string","description":"Start of date range filter on irr.created_at.","title":"Start Date"},"description":"Start of date range filter on irr.created_at."},{"name":"end_date","in":"query","required":true,"schema":{"type":"string","description":"End of date range filter on irr.created_at.","title":"End Date"},"description":"End of date range filter on irr.created_at."},{"name":"campaign_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Campaign Id"}},{"name":"publisher_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publisher Id"}},{"name":"buyer_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Id"}},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search"}},{"name":"sort","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"One of: created_at, campaign_name, publisher_name, buyer_name, target_number, caller_id, duration, publisher_payout, total_routes, eligible_routes_count.","title":"Sort"},"description":"One of: created_at, campaign_name, publisher_name, buyer_name, target_number, caller_id, duration, publisher_payout, total_routes, eligible_routes_count."},{"name":"sort_direction","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"'asc' or 'desc'.","title":"Sort Direction"},"description":"'asc' or 'desc'."},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboundRtbRequestsListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/inbound-rtb/requests/{request_id}/life-logs":{"get":{"tags":["Inbound RTB"],"summary":"Inbound RTB life logs by request","description":"Life log events for an inbound RTB request ID, scoped to the organization from your API key. Same data as `GET /inbound_rtb/life-logs/by-request/{request_id}` in the product API, authenticated with an organization API key.","operationId":"get_inbound_rtb_life_logs_by_request_inbound_rtb_requests__request_id__life_logs_get","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","title":"Request Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LifeLogsByRequestResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"503":{"description":"Data store unavailable or disabled"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/inbound-rtb/allocations/by-request/{request_id}":{"get":{"tags":["Inbound RTB"],"summary":"Allocations for an inbound RTB request","operationId":"inbound_rtb_allocations_by_request_inbound_rtb_allocations_by_request__request_id__get","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","title":"Request Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboundRtbAllocationsByRequestResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/inbound-rtb/stats/summary":{"get":{"tags":["Inbound RTB"],"summary":"Aggregate inbound RTB stats","operationId":"inbound_rtb_stats_summary_inbound_rtb_stats_summary_get","parameters":[{"name":"start_date","in":"query","required":true,"schema":{"type":"string","title":"Start Date"}},{"name":"end_date","in":"query","required":true,"schema":{"type":"string","title":"End Date"}},{"name":"campaign_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Campaign Id"}},{"name":"publisher_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publisher Id"}},{"name":"buyer_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboundRtbStatsSummaryResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/inbound-rtb/{inbound_rtb_id}":{"get":{"tags":["Inbound RTB"],"summary":"Get an inbound RTB","operationId":"get_inbound_rtb_inbound_rtb__inbound_rtb_id__get","parameters":[{"name":"inbound_rtb_id","in":"path","required":true,"schema":{"type":"string","title":"Inbound Rtb Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboundRtbResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"patch":{"tags":["Inbound RTB"],"summary":"Patch an inbound RTB","operationId":"patch_inbound_rtb_inbound_rtb__inbound_rtb_id__patch","parameters":[{"name":"inbound_rtb_id","in":"path","required":true,"schema":{"type":"string","title":"Inbound Rtb Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboundRtbPatch"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboundRtbResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"delete":{"tags":["Inbound RTB"],"summary":"Delete an inbound RTB","operationId":"delete_inbound_rtb_inbound_rtb__inbound_rtb_id__delete","parameters":[{"name":"inbound_rtb_id","in":"path","required":true,"schema":{"type":"string","title":"Inbound Rtb Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"204":{"description":"Successful Response"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/outbound-rtb/stats/summary":{"get":{"tags":["Outbound RTB analytics"],"summary":"Aggregate outbound RTB stats","operationId":"outbound_rtb_stats_summary_outbound_rtb_stats_summary_get","parameters":[{"name":"start_date","in":"query","required":true,"schema":{"type":"string","description":"Start of range on rr.start_time.","title":"Start Date"},"description":"Start of range on rr.start_time."},{"name":"end_date","in":"query","required":true,"schema":{"type":"string","description":"End of range on rr.start_time.","title":"End Date"},"description":"End of range on rr.start_time."},{"name":"campaign_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Campaign Id"}},{"name":"publisher_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publisher Id"}},{"name":"buyer_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutboundRtbStatsSummaryResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/outbound-rtb/requests":{"get":{"tags":["Outbound RTB analytics"],"summary":"Paginated outbound RTB request list","operationId":"outbound_rtb_requests_outbound_rtb_requests_get","parameters":[{"name":"start_date","in":"query","required":true,"schema":{"type":"string","title":"Start Date"}},{"name":"end_date","in":"query","required":true,"schema":{"type":"string","title":"End Date"}},{"name":"campaign_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Campaign Id"}},{"name":"publisher_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publisher Id"}},{"name":"buyer_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Id"}},{"name":"request_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by outbound RTB request ID (partial match)","title":"Request Id"},"description":"Filter by outbound RTB request ID (partial match)"},{"name":"group_name","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by RTB group name (partial match)","title":"Group Name"},"description":"Filter by RTB group name (partial match)"},{"name":"inbound_rtb_request_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by inbound RTB request ID (partial match)","title":"Inbound Rtb Request Id"},"description":"Filter by inbound RTB request ID (partial match)"},{"name":"state","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by state (partial match)","title":"State"},"description":"Filter by state (partial match)"},{"name":"caller_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by caller ID (partial match)","title":"Caller Id"},"description":"Filter by caller ID (partial match)"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutboundRtbRequestsListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/outbound-rtb/requests/{request_id}/steps":{"get":{"tags":["Outbound RTB analytics"],"summary":"HTTP steps for an outbound RTB request","operationId":"outbound_rtb_request_steps_outbound_rtb_requests__request_id__steps_get","parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string","title":"Request Id"}},{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutboundRtbRequestStepsResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/media/prompts":{"post":{"tags":["Media"],"summary":"Upload an organization-scoped audio prompt","description":"Upload base64 MP3 or 16-bit PCM WAV (5 MiB, ten minutes maximum). Store filePath in play/gather nodes; no expiring URL is returned. Identical bytes in the same organization reuse the same key.","operationId":"upload_prompt_media_prompts_post","parameters":[{"name":"X-API-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Api-Key"}},{"name":"Authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MediaUploadResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"413":{"description":"Upload exceeds size limit"},"415":{"description":"Expected JSON"},"503":{"description":"Prompt storage unavailable"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"additionalProperties":false,"properties":{"fileName":{"maxLength":255,"minLength":1,"pattern":"^[A-Za-z0-9][A-Za-z0-9 _().-]*\\.(mp3|wav)$","title":"Filename","type":"string"},"fileType":{"enum":["audio/mpeg","audio/wav","audio/x-wav"],"title":"Filetype","type":"string"},"fileContent":{"maxLength":6990508,"minLength":4,"title":"Filecontent","type":"string"}},"required":["fileName","fileType","fileContent"],"title":"MediaUploadRequest","type":"object"}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/number-pools":{"get":{"tags":["Number pools"],"summary":"List number pools","operationId":"listNumberPools","parameters":[{"name":"include_statistics","in":"query","required":false,"schema":{"type":"boolean","description":"Whether to include statistics for each number pool","default":true,"title":"Include Statistics"},"description":"Whether to include statistics for each number pool"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NumberPoolListResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"500":{"description":"Internal server error"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"post":{"tags":["Number pools"],"summary":"Create a number pool","operationId":"createNumberPool","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NumberPoolCreateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NumberPoolResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"500":{"description":"Internal server error"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/number-pools/{number_pool_id}":{"get":{"tags":["Number pools"],"summary":"Get a number pool","operationId":"getNumberPool","parameters":[{"name":"number_pool_id","in":"path","required":true,"schema":{"type":"string","title":"Number Pool Id"}},{"name":"include_numbers","in":"query","required":false,"schema":{"type":"boolean","description":"Whether to include phone numbers in the response","default":false,"title":"Include Numbers"},"description":"Whether to include phone numbers in the response"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NumberPoolResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"500":{"description":"Internal server error"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"put":{"tags":["Number pools"],"summary":"Replace a number pool","operationId":"putNumberPool","parameters":[{"name":"number_pool_id","in":"path","required":true,"schema":{"type":"string","title":"Number Pool Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NumberPoolUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NumberPoolResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"500":{"description":"Internal server error"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"patch":{"tags":["Number pools"],"summary":"Update a number pool","operationId":"patchNumberPool","parameters":[{"name":"number_pool_id","in":"path","required":true,"schema":{"type":"string","title":"Number Pool Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NumberPoolUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NumberPoolResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"500":{"description":"Internal server error"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]},"delete":{"tags":["Number pools"],"summary":"Delete a number pool","operationId":"deleteNumberPool","parameters":[{"name":"number_pool_id","in":"path","required":true,"schema":{"type":"string","title":"Number Pool Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NumberPoolDeleteResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"500":{"description":"Internal server error"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/number-pools/{number_pool_id}/statistics":{"get":{"tags":["Number pools"],"summary":"Get number pool statistics","operationId":"getNumberPoolStatistics","parameters":[{"name":"number_pool_id","in":"path","required":true,"schema":{"type":"string","title":"Number Pool Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NumberPoolStatisticsEnvelopeResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"500":{"description":"Internal server error"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/number-pools/{number_pool_id}/order-status":{"get":{"tags":["Number pools"],"summary":"Get number pool order status","operationId":"getNumberPoolOrderStatus","parameters":[{"name":"number_pool_id","in":"path","required":true,"schema":{"type":"string","title":"Number Pool Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NumberPoolOrderStatusResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"500":{"description":"Internal server error"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}},"/api/v1/number-pools/{number_pool_id}/orders":{"get":{"tags":["Number pools"],"summary":"List number pool orders","operationId":"listNumberPoolOrders","parameters":[{"name":"number_pool_id","in":"path","required":true,"schema":{"type":"string","title":"Number Pool Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NumberPoolOrdersResponse"}}}},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Bad Request"},"401":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Unauthorized"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Not Found"},"409":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Conflict"},"429":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Too Many Requests"},"500":{"description":"Internal server error"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"MojaApiKeyHeader":[]},{"MojaApiBearer":[]}]}}},"components":{"schemas":{"AuditLogDetail":{"properties":{"id":{"type":"string","title":"Id"},"org_id":{"type":"string","title":"Org Id"},"user_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id"},"user_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Email"},"impersonated_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Impersonated By","description":"Clerk user id of the impersonator (JWT act.sub) when the change was made during impersonation"},"user_role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Role"},"is_internal":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Internal"},"api_key_prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Api Key Prefix"},"entity_type":{"type":"string","title":"Entity Type"},"entity_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Id"},"entity_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Name","description":"Human-readable entity label when available (from snapshot)"},"action":{"type":"string","title":"Action"},"route":{"type":"string","title":"Route"},"method":{"type":"string","title":"Method"},"status_code":{"type":"integer","title":"Status Code"},"changes":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Changes"},"trace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trace Id"},"client_ip":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Ip"},"user_agent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Agent"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"before_snapshot":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Before Snapshot"},"after_snapshot":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"After Snapshot"}},"type":"object","required":["id","org_id","entity_type","action","route","method","status_code","created_at"],"title":"AuditLogDetail"},"AuditLogFieldChangeItem":{"properties":{"id":{"type":"string","title":"Id","description":"Stable row id: audit_log_id:field_path"},"audit_log_id":{"type":"string","title":"Audit Log Id"},"field":{"type":"string","title":"Field","description":"Raw dotted path in changes JSON"},"field_label":{"type":"string","title":"Field Label","description":"Human-readable field label for display"},"old_value":{"anyOf":[{},{"type":"null"}],"title":"Old Value"},"new_value":{"anyOf":[{},{"type":"null"}],"title":"New Value"},"org_id":{"type":"string","title":"Org Id"},"user_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id"},"user_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Email"},"impersonated_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Impersonated By"},"user_role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Role"},"is_internal":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Internal"},"api_key_prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Api Key Prefix"},"entity_type":{"type":"string","title":"Entity Type"},"entity_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Id"},"entity_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Name"},"action":{"type":"string","title":"Action"},"route":{"type":"string","title":"Route"},"method":{"type":"string","title":"Method"},"status_code":{"type":"integer","title":"Status Code"},"trace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trace Id"},"client_ip":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Ip"},"user_agent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Agent"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","audit_log_id","field","field_label","org_id","entity_type","action","route","method","status_code","created_at"],"title":"AuditLogFieldChangeItem","description":"One changed field from an audit event (flattened read model)."},"AuditLogFieldChangeListResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/AuditLogFieldChangeItem"},"type":"array","title":"Data"},"total":{"type":"integer","title":"Total","description":"Total field-change rows matching filters (not audit event count)"},"limit":{"type":"integer","maximum":500.0,"minimum":1.0,"title":"Limit"},"offset":{"type":"integer","minimum":0.0,"title":"Offset"}},"type":"object","required":["data","total","limit","offset"],"title":"AuditLogFieldChangeListResponse"},"AuditLogItem":{"properties":{"id":{"type":"string","title":"Id"},"org_id":{"type":"string","title":"Org Id"},"user_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Id"},"user_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Email"},"impersonated_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Impersonated By","description":"Clerk user id of the impersonator (JWT act.sub) when the change was made during impersonation"},"user_role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Role"},"is_internal":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Internal"},"api_key_prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Api Key Prefix"},"entity_type":{"type":"string","title":"Entity Type"},"entity_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Id"},"entity_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Name","description":"Human-readable entity label when available (from snapshot)"},"action":{"type":"string","title":"Action"},"route":{"type":"string","title":"Route"},"method":{"type":"string","title":"Method"},"status_code":{"type":"integer","title":"Status Code"},"changes":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Changes"},"trace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trace Id"},"client_ip":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Ip"},"user_agent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Agent"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","org_id","entity_type","action","route","method","status_code","created_at"],"title":"AuditLogItem"},"AuditLogListResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/AuditLogItem"},"type":"array","title":"Data"},"total":{"type":"integer","title":"Total"},"limit":{"type":"integer","maximum":500.0,"minimum":1.0,"title":"Limit"},"offset":{"type":"integer","minimum":0.0,"title":"Offset"}},"type":"object","required":["data","total","limit","offset"],"title":"AuditLogListResponse"},"BulkPauseRequest":{"properties":{"duration_minutes":{"anyOf":[{"type":"integer","maximum":43200.0,"minimum":1.0},{"type":"null"}],"title":"Duration Minutes"},"paused_until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Paused Until"},"unlimited":{"type":"boolean","title":"Unlimited","default":false},"items":{"items":{"$ref":"#/components/schemas/PauseItemRef"},"type":"array","minItems":1,"title":"Items"}},"additionalProperties":false,"type":"object","required":["items"],"title":"BulkPauseRequest"},"BulkPauseResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/BulkPauseResultItem"},"type":"array","title":"Data"}},"additionalProperties":false,"type":"object","required":["data"],"title":"BulkPauseResponse"},"BulkPauseResultItem":{"properties":{"type":{"type":"string","enum":["target","rtb"],"title":"Type"},"id":{"type":"string","title":"Id"},"paused_until":{"type":"string","format":"date-time","title":"Paused Until"}},"additionalProperties":false,"type":"object","required":["type","id","paused_until"],"title":"BulkPauseResultItem"},"BulkResumeRequest":{"properties":{"items":{"items":{"$ref":"#/components/schemas/PauseItemRef"},"type":"array","minItems":1,"title":"Items"}},"additionalProperties":false,"type":"object","required":["items"],"title":"BulkResumeRequest"},"BulkResumeResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/BulkResumeResultItem"},"type":"array","title":"Data"}},"additionalProperties":false,"type":"object","required":["data"],"title":"BulkResumeResponse"},"BulkResumeResultItem":{"properties":{"type":{"type":"string","enum":["target","rtb"],"title":"Type"},"id":{"type":"string","title":"Id"}},"additionalProperties":false,"type":"object","required":["type","id"],"title":"BulkResumeResultItem"},"BuyerCreate":{"properties":{"name":{"type":"string","minLength":1,"title":"Name"},"street_address":{"type":"string","title":"Street Address"},"city":{"type":"string","title":"City"},"state":{"type":"string","title":"State"},"zip_code":{"type":"string","title":"Zip Code"},"country":{"type":"string","title":"Country"},"phone_number":{"type":"string","title":"Phone Number"},"email":{"type":"string","title":"Email","default":""},"total_revenue_limit":{"type":"number","title":"Total Revenue Limit"},"timezone":{"type":"string","title":"Timezone","default":"America/New_York"},"permalink":{"type":"string","title":"Permalink","default":""},"disable_recordings":{"type":"boolean","title":"Disable Recordings","default":false},"access_to_call_recordings":{"type":"boolean","title":"Access To Call Recordings","default":true},"is_active":{"type":"boolean","title":"Is Active"},"advanced_caps":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Advanced Caps"},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id","description":"External system ID for migration purposes"}},"additionalProperties":false,"type":"object","required":["name","street_address","city","state","zip_code","country","phone_number","total_revenue_limit","is_active"],"title":"BuyerCreate"},"BuyerListResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/BuyerResponse"},"type":"array","title":"Data"},"meta":{"$ref":"#/components/schemas/PaginatedResponseMeta"}},"additionalProperties":false,"type":"object","required":["data","meta"],"title":"BuyerListResponse"},"BuyerPatch":{"properties":{"name":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}],"title":"Name"},"street_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Street Address"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"},"zip_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Zip Code"},"country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Country"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone Number"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"total_revenue_limit":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Total Revenue Limit"},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone"},"permalink":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Permalink"},"disable_recordings":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Disable Recordings"},"access_to_call_recordings":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Access To Call Recordings"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"advanced_caps":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Advanced Caps"},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id","description":"External system ID for migration purposes"}},"additionalProperties":false,"type":"object","title":"BuyerPatch"},"BuyerResponse":{"properties":{"id":{"type":"string","title":"Id"},"org_id":{"type":"string","title":"Org Id"},"name":{"type":"string","title":"Name"},"street_address":{"type":"string","title":"Street Address"},"city":{"type":"string","title":"City"},"state":{"type":"string","title":"State"},"zip_code":{"type":"string","title":"Zip Code"},"country":{"type":"string","title":"Country"},"phone_number":{"type":"string","title":"Phone Number"},"email":{"type":"string","title":"Email"},"total_revenue_limit":{"type":"number","title":"Total Revenue Limit"},"timezone":{"type":"string","title":"Timezone"},"permalink":{"type":"string","title":"Permalink"},"disable_recordings":{"type":"boolean","title":"Disable Recordings","default":false},"access_to_call_recordings":{"type":"boolean","title":"Access To Call Recordings"},"is_active":{"type":"boolean","title":"Is Active"},"hourly":{"type":"integer","title":"Hourly","default":0},"daily":{"type":"integer","title":"Daily","default":0},"weekly":{"type":"integer","title":"Weekly","default":0},"monthly":{"type":"integer","title":"Monthly","default":0},"yearly":{"type":"integer","title":"Yearly","default":0},"total":{"type":"integer","title":"Total","default":0},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"targets":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Targets"},"advanced_caps":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Advanced Caps"}},"additionalProperties":false,"type":"object","required":["id","org_id","name","street_address","city","state","zip_code","country","phone_number","email","total_revenue_limit","timezone","permalink","access_to_call_recordings","is_active"],"title":"BuyerResponse"},"CallFlowCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"external_id":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"External Id"},"data":{"additionalProperties":true,"type":"object","title":"Data"}},"additionalProperties":false,"type":"object","required":["name","data"],"title":"CallFlowCreate"},"CallFlowListResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/CallFlowResponse"},"type":"array","title":"Data"},"meta":{"$ref":"#/components/schemas/PaginatedResponseMeta"}},"additionalProperties":false,"type":"object","required":["data","meta"],"title":"CallFlowListResponse"},"CallFlowMediaBinding":{"properties":{"node_id":{"type":"string","maxLength":255,"minLength":1,"title":"Node Id"},"node_type":{"type":"string","pattern":"^(play|gather)$","title":"Node Type"},"filePath":{"type":"string","maxLength":1024,"minLength":1,"title":"Filepath"},"bucketName":{"type":"string","maxLength":255,"minLength":1,"title":"Bucketname"},"audioFileName":{"type":"string","maxLength":255,"minLength":1,"title":"Audiofilename"}},"additionalProperties":false,"type":"object","required":["node_id","node_type","filePath","bucketName","audioFileName"],"title":"CallFlowMediaBinding"},"CallFlowMediaPatch":{"properties":{"bindings":{"items":{"$ref":"#/components/schemas/CallFlowMediaBinding"},"type":"array","maxItems":1000,"minItems":1,"title":"Bindings"}},"additionalProperties":false,"type":"object","required":["bindings"],"title":"CallFlowMediaPatch"},"CallFlowPatch":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Name"},"external_id":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"External Id"},"data":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Data"}},"additionalProperties":false,"type":"object","title":"CallFlowPatch"},"CallFlowResponse":{"properties":{"id":{"type":"string","title":"Id"},"org_id":{"type":"string","title":"Org Id"},"name":{"type":"string","title":"Name"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id"},"data":{"additionalProperties":true,"type":"object","title":"Data"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"additionalProperties":false,"type":"object","required":["id","org_id","name","data"],"title":"CallFlowResponse"},"CallLifeEvent":{"properties":{"id":{"type":"string","title":"Id"},"call_id":{"type":"string","title":"Call Id"},"event_time":{"type":"string","title":"Event Time"},"title":{"type":"string","title":"Title"},"details":{"additionalProperties":true,"type":"object","title":"Details"},"org_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Org Id"}},"additionalProperties":false,"type":"object","required":["id","call_id","event_time","title","details"],"title":"CallLifeEvent","description":"Single call life timeline row (same shape as legacy `GET /reporting/call-life/{call_id}` events)."},"CallLifeResponse":{"properties":{"call_id":{"type":"string","title":"Call Id"},"events":{"items":{"$ref":"#/components/schemas/CallLifeEvent"},"type":"array","title":"Events"}},"additionalProperties":false,"type":"object","required":["call_id","events"],"title":"CallLifeResponse","description":"Call life timeline for a call id (same payload as legacy portal)."},"CampaignCreate":{"properties":{"sticky_caller_enabled":{"type":"boolean","title":"Sticky Caller Enabled","default":false},"sticky_caller_action":{"type":"string","enum":["route_to_same_buyer","decline"],"title":"Sticky Caller Action","default":"route_to_same_buyer"},"sticky_caller_lookback_value":{"type":"integer","maximum":2147483647.0,"minimum":1.0,"title":"Sticky Caller Lookback Value","default":30},"sticky_caller_lookback_unit":{"type":"string","enum":["hours","days","weeks","months"],"title":"Sticky Caller Lookback Unit","default":"days"},"sticky_caller_scope":{"type":"string","enum":["campaign","listed"],"title":"Sticky Caller Scope","default":"campaign"},"sticky_caller_entities":{"items":{"$ref":"#/components/schemas/CampaignStickyCallerEntity"},"type":"array","title":"Sticky Caller Entities"},"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"routing_plan_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Routing Plan Id"},"call_flow_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Flow Id"},"execution_mode":{"type":"string","enum":["routing_plan","call_flow"],"title":"Execution Mode","default":"routing_plan"},"is_active":{"type":"boolean","title":"Is Active","default":false},"payout":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Payout"},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone","default":"America/New_York","examples":["America/New_York"]},"conversion_scope":{"type":"integer","minimum":0.0,"title":"Conversion Scope","default":10},"qai_category_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Qai Category Id"},"tcpa_scrubbing":{"anyOf":[{"type":"string","enum":["default","blacklist-alliance"]},{"type":"null"}],"title":"Tcpa Scrubbing"},"tcpa_scrubbing_config":{"anyOf":[{"$ref":"#/components/schemas/CampaignTCPAScrubbingConfig"},{"type":"null"}]},"number_group_items":{"items":{"$ref":"#/components/schemas/CampaignNumberGroupItemWrite"},"type":"array","title":"Number Group Items"},"ivr_payout_rules":{"items":{"$ref":"#/components/schemas/CampaignIVRPayoutRule"},"type":"array","title":"Ivr Payout Rules"},"outgoing_webhooks":{"items":{"type":"string"},"type":"array","title":"Outgoing Webhooks"},"incoming_webhooks":{"items":{"type":"string"},"type":"array","title":"Incoming Webhooks"},"preconverted_caller":{"type":"boolean","title":"Preconverted Caller","default":false},"preconverted_destination":{"type":"boolean","title":"Preconverted Destination","default":false},"preconverted_publisher":{"type":"boolean","title":"Preconverted Publisher","default":false},"preconverted_campaign":{"type":"boolean","title":"Preconverted Campaign","default":false},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id","description":"External system ID for migration purposes"},"disable_recordings":{"type":"boolean","title":"Disable Recordings","default":false},"access_to_call_recordings":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Access To Call Recordings"},"expose_ineligible_routes":{"type":"boolean","title":"Expose Ineligible Routes","default":false},"ineligible_routes_fields":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ineligible Routes Fields"},"advanced_caps":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Advanced Caps","description":"Publisher-scoped advanced caps for this campaign; each cap must include publisher_id."}},"additionalProperties":false,"type":"object","required":["name"],"title":"CampaignCreate"},"CampaignIVRPayoutRule":{"properties":{"id":{"anyOf":[{"type":"string","maxLength":36,"minLength":1},{"type":"null"}],"title":"Id"},"legacy_rule_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Legacy Rule Id"},"combinator":{"type":"string","enum":["and","or"],"title":"Combinator","default":"and"},"payout":{"type":"number","title":"Payout","default":0.0},"filters":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Filters","examples":[[{"field":"keypress","operator":"equals","value":"1"}]]}},"additionalProperties":false,"type":"object","title":"CampaignIVRPayoutRule","description":"``id`` is ``campaign_ivr_payout_rules.uuid``; ``legacy_rule_id`` is the legacy JSON rule key when distinct."},"CampaignListResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/CampaignResponse"},"type":"array","title":"Data"},"meta":{"$ref":"#/components/schemas/PaginatedResponseMeta"}},"additionalProperties":false,"type":"object","required":["data","meta"],"title":"CampaignListResponse"},"CampaignNumberGroupItem":{"properties":{"id":{"anyOf":[{"type":"string","maxLength":36,"minLength":1},{"type":"null"}],"title":"Id"},"number_id":{"type":"string","title":"Number Id"},"publisher_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publisher Id"},"type":{"type":"string","enum":["static","dynamic"],"title":"Type","default":"static"},"payout":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Payout"},"payout_condition":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payout Condition"},"payout_condition_duration":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Payout Condition Duration"},"payout_percentage":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Payout Percentage"},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id","description":"External system ID for migration purposes"},"is_active":{"type":"boolean","title":"Is Active","default":true},"number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Number"},"publisher_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publisher Name"},"paused_until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Paused Until"},"paused_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Paused At"},"paused_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Paused By"},"is_paused":{"type":"boolean","title":"Is Paused","default":false}},"additionalProperties":false,"type":"object","required":["number_id"],"title":"CampaignNumberGroupItem","description":"``id`` is ``campaign_number_group_items.uuid`` (stable row id). Includes pause state on reads."},"CampaignNumberGroupItemWrite":{"properties":{"id":{"anyOf":[{"type":"string","maxLength":36,"minLength":1},{"type":"null"}],"title":"Id"},"number_id":{"type":"string","title":"Number Id"},"publisher_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publisher Id"},"type":{"type":"string","enum":["static","dynamic"],"title":"Type","default":"static"},"payout":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Payout"},"payout_condition":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payout Condition"},"payout_condition_duration":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Payout Condition Duration"},"payout_percentage":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Payout Percentage"},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id","description":"External system ID for migration purposes"},"is_active":{"type":"boolean","title":"Is Active","default":true}},"additionalProperties":false,"type":"object","required":["number_id"],"title":"CampaignNumberGroupItemWrite","description":"Writable number-group fields. Pause is managed via ``/entity_pause/campaign_numbers``."},"CampaignPatch":{"properties":{"sticky_caller_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Sticky Caller Enabled"},"sticky_caller_action":{"anyOf":[{"type":"string","enum":["route_to_same_buyer","decline"]},{"type":"null"}],"title":"Sticky Caller Action"},"sticky_caller_lookback_value":{"anyOf":[{"type":"integer","maximum":2147483647.0,"minimum":1.0},{"type":"null"}],"title":"Sticky Caller Lookback Value"},"sticky_caller_lookback_unit":{"anyOf":[{"type":"string","enum":["hours","days","weeks","months"]},{"type":"null"}],"title":"Sticky Caller Lookback Unit"},"sticky_caller_scope":{"anyOf":[{"type":"string","enum":["campaign","listed"]},{"type":"null"}],"title":"Sticky Caller Scope"},"sticky_caller_entities":{"anyOf":[{"items":{"$ref":"#/components/schemas/CampaignStickyCallerEntity"},"type":"array"},{"type":"null"}],"title":"Sticky Caller Entities"},"name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Name"},"routing_plan_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Routing Plan Id"},"call_flow_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Flow Id"},"execution_mode":{"anyOf":[{"type":"string","enum":["routing_plan","call_flow"]},{"type":"null"}],"title":"Execution Mode"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"payout":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Payout"},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone","examples":["America/New_York"]},"conversion_scope":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Conversion Scope"},"qai_category_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Qai Category Id"},"tcpa_scrubbing":{"anyOf":[{"type":"string","enum":["default","blacklist-alliance"]},{"type":"null"}],"title":"Tcpa Scrubbing"},"tcpa_scrubbing_config":{"anyOf":[{"$ref":"#/components/schemas/CampaignTCPAScrubbingConfig"},{"type":"null"}]},"number_group_items":{"anyOf":[{"items":{"$ref":"#/components/schemas/CampaignNumberGroupItemWrite"},"type":"array"},{"type":"null"}],"title":"Number Group Items"},"ivr_payout_rules":{"anyOf":[{"items":{"$ref":"#/components/schemas/CampaignIVRPayoutRule"},"type":"array"},{"type":"null"}],"title":"Ivr Payout Rules"},"outgoing_webhooks":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Outgoing Webhooks"},"incoming_webhooks":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Incoming Webhooks"},"preconverted_caller":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Preconverted Caller"},"preconverted_destination":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Preconverted Destination"},"preconverted_publisher":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Preconverted Publisher"},"preconverted_campaign":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Preconverted Campaign"},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id","description":"External system ID for migration purposes"},"disable_recordings":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Disable Recordings"},"access_to_call_recordings":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Access To Call Recordings"},"expose_ineligible_routes":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Expose Ineligible Routes"},"ineligible_routes_fields":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ineligible Routes Fields"},"advanced_caps":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Advanced Caps","description":"Publisher-scoped advanced caps for this campaign; each cap must include publisher_id."}},"additionalProperties":false,"type":"object","title":"CampaignPatch"},"CampaignResponse":{"properties":{"id":{"type":"string","title":"Id"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"sticky_caller_enabled":{"type":"boolean","title":"Sticky Caller Enabled","default":false},"sticky_caller_action":{"type":"string","enum":["route_to_same_buyer","decline"],"title":"Sticky Caller Action","default":"route_to_same_buyer"},"sticky_caller_lookback_value":{"type":"integer","title":"Sticky Caller Lookback Value","default":30},"sticky_caller_lookback_unit":{"type":"string","enum":["hours","days","weeks","months"],"title":"Sticky Caller Lookback Unit","default":"days"},"sticky_caller_scope":{"type":"string","enum":["campaign","listed"],"title":"Sticky Caller Scope","default":"campaign"},"sticky_caller_entities":{"items":{"$ref":"#/components/schemas/CampaignStickyCallerEntity"},"type":"array","title":"Sticky Caller Entities"},"name":{"type":"string","title":"Name"},"org_id":{"type":"string","title":"Org Id"},"routing_plan_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Routing Plan Id"},"call_flow_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Flow Id"},"execution_mode":{"type":"string","title":"Execution Mode"},"is_active":{"type":"boolean","title":"Is Active"},"payout":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Payout"},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone"},"conversion_scope":{"type":"integer","title":"Conversion Scope"},"qai_category_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Qai Category Id"},"tcpa_scrubbing":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tcpa Scrubbing"},"tcpa_scrubbing_config":{"anyOf":[{"$ref":"#/components/schemas/CampaignTCPAScrubbingConfig"},{"type":"null"}]},"number_group_items":{"items":{"$ref":"#/components/schemas/CampaignNumberGroupItem"},"type":"array","title":"Number Group Items"},"ivr_payout_rules":{"items":{"$ref":"#/components/schemas/CampaignIVRPayoutRule"},"type":"array","title":"Ivr Payout Rules"},"outgoing_webhooks":{"items":{"type":"string"},"type":"array","title":"Outgoing Webhooks"},"incoming_webhooks":{"items":{"type":"string"},"type":"array","title":"Incoming Webhooks"},"preconverted_caller":{"type":"boolean","title":"Preconverted Caller","default":false},"preconverted_destination":{"type":"boolean","title":"Preconverted Destination","default":false},"preconverted_publisher":{"type":"boolean","title":"Preconverted Publisher","default":false},"preconverted_campaign":{"type":"boolean","title":"Preconverted Campaign","default":false},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id"},"disable_recordings":{"type":"boolean","title":"Disable Recordings","default":false},"access_to_call_recordings":{"type":"boolean","title":"Access To Call Recordings"},"expose_ineligible_routes":{"type":"boolean","title":"Expose Ineligible Routes","default":false},"ineligible_routes_fields":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ineligible Routes Fields"},"routing_plan":{"anyOf":[{"$ref":"#/components/schemas/ResourceRef"},{"type":"null"}]},"advanced_caps":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Advanced Caps"}},"additionalProperties":false,"type":"object","required":["id","name","org_id","execution_mode","is_active","conversion_scope","access_to_call_recordings"],"title":"CampaignResponse"},"CampaignStickyCallerEntity":{"properties":{"entity_type":{"type":"string","enum":["target","buyer"],"title":"Entity Type"},"entity_id":{"type":"string","maxLength":255,"minLength":1,"title":"Entity Id"},"lookback_value":{"type":"integer","maximum":2147483647.0,"minimum":1.0,"title":"Lookback Value","default":30},"lookback_unit":{"type":"string","enum":["hours","days","weeks","months"],"title":"Lookback Unit","default":"days"}},"additionalProperties":false,"type":"object","required":["entity_type","entity_id"],"title":"CampaignStickyCallerEntity"},"CampaignTCPAScrubbingConfig":{"properties":{"id":{"anyOf":[{"type":"string","maxLength":36,"minLength":1},{"type":"null"}],"title":"Id"},"api_key":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Api Key"},"api_version":{"anyOf":[{"type":"string","enum":["v1","v2","v3"]},{"type":"null"}],"title":"Api Version","default":"v1"},"api_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Api Url","examples":["https://api.blacklistalliance.net/lookup?key=abc123&ver=v1&resp=raw&phone="]},"allow_calls_on_failure":{"type":"boolean","title":"Allow Calls On Failure","default":true}},"additionalProperties":false,"type":"object","title":"CampaignTCPAScrubbingConfig","description":"``id`` is the DB row uuid (``campaign_tcpa_scrubbing_configs.uuid``) for stable PATCH round-trips."},"Country":{"type":"string","enum":["US"],"title":"Country"},"CustomTagCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name","examples":["sub_1"]},"display_name":{"type":"string","maxLength":255,"minLength":1,"title":"Display Name","examples":["Sub ID 1"]},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"}},"additionalProperties":false,"type":"object","required":["name","display_name"],"title":"CustomTagCreate"},"CustomTagListResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/CustomTagResponse"},"type":"array","title":"Data"},"meta":{"$ref":"#/components/schemas/PaginatedResponseMeta"}},"additionalProperties":false,"type":"object","required":["data","meta"],"title":"CustomTagListResponse"},"CustomTagPatch":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Name","examples":["sub_1"]},"display_name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Display Name","examples":["Sub ID 1"]},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"}},"additionalProperties":false,"type":"object","title":"CustomTagPatch"},"CustomTagResponse":{"properties":{"id":{"type":"string","title":"Id"},"org_id":{"type":"string","title":"Org Id"},"name":{"type":"string","title":"Name"},"display_name":{"type":"string","title":"Display Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"additionalProperties":false,"type":"object","required":["id","org_id","name","display_name"],"title":"CustomTagResponse"},"ErrorBody":{"properties":{"code":{"type":"string","title":"Code"},"message":{"type":"string","title":"Message"}},"additionalProperties":false,"type":"object","required":["code","message"],"title":"ErrorBody"},"ErrorResponse":{"properties":{"detail":{"$ref":"#/components/schemas/ErrorBody"}},"additionalProperties":false,"type":"object","required":["detail"],"title":"ErrorResponse"},"EventTypeResponse":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"internal_name":{"type":"string","title":"Internal Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"}},"additionalProperties":false,"type":"object","required":["id","name","internal_name"],"title":"EventTypeResponse"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"InboundRtbAllocationRow":{"properties":{"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id"},"inbound_rtb_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inbound Rtb Id"},"number_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Number Id"},"buyer_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Id"},"buyer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Name"},"routing_plan_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Routing Plan Id"},"call_log_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Log Id"},"request_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Request Id"},"target_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Number"},"target_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Type"},"target_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Name"},"payout":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Payout"},"target_payout":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Target Payout"},"payout_condition":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payout Condition"},"payout_condition_duration":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Payout Condition Duration"},"start_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start Date"},"expiry_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expiry Date"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"additionalProperties":true,"type":"object","title":"InboundRtbAllocationRow"},"InboundRtbAllocationsByRequestResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/InboundRtbAllocationRow"},"type":"array","title":"Data"}},"additionalProperties":false,"type":"object","required":["data"],"title":"InboundRtbAllocationsByRequestResponse"},"InboundRtbCreate":{"properties":{"inbound_rtb_id":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Inbound Rtb Id"},"campaign_id":{"type":"string","maxLength":255,"minLength":1,"title":"Campaign Id"},"publisher_id":{"type":"string","maxLength":255,"minLength":1,"title":"Publisher Id"},"payout_mode":{"type":"string","enum":["dynamic","static"],"title":"Payout Mode","default":"dynamic"},"payout_percentage":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Payout Percentage","default":80.0},"duration_add_seconds":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Duration Add Seconds","default":0},"payout":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Payout"},"payout_condition":{"anyOf":[{"type":"string","enum":["call_length_connected","call_length_incoming","call_successfully_connected","call_converted"]},{"type":"null"}],"title":"Payout Condition"},"payout_condition_duration":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Payout Condition Duration"},"allocation_time_seconds":{"type":"integer","maximum":60.0,"minimum":1.0,"title":"Allocation Time Seconds","default":60},"rate_limit":{"type":"integer","minimum":1.0,"title":"Rate Limit","default":100},"rate_period":{"type":"string","enum":["min","hour","day"],"title":"Rate Period","default":"min"},"is_active":{"type":"boolean","title":"Is Active","default":true},"receive_mode":{"type":"string","enum":["dynamic","static_standard","static_multi_bid"],"title":"Receive Mode","default":"dynamic"},"receive_number_id":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Receive Number Id"},"call_flow_id":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Call Flow Id"},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id","description":"External system ID for migration purposes"}},"additionalProperties":false,"type":"object","required":["campaign_id","publisher_id"],"title":"InboundRtbCreate"},"InboundRtbListResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/InboundRtbResponse"},"type":"array","title":"Data"},"meta":{"$ref":"#/components/schemas/PaginatedResponseMeta"}},"additionalProperties":false,"type":"object","required":["data","meta"],"title":"InboundRtbListResponse"},"InboundRtbPatch":{"properties":{"inbound_rtb_id":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Inbound Rtb Id"},"payout_mode":{"anyOf":[{"type":"string","enum":["dynamic","static"]},{"type":"null"}],"title":"Payout Mode"},"payout_percentage":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Payout Percentage"},"duration_add_seconds":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Duration Add Seconds"},"payout":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Payout"},"payout_condition":{"anyOf":[{"type":"string","enum":["call_length_connected","call_length_incoming","call_successfully_connected","call_converted"]},{"type":"null"}],"title":"Payout Condition"},"payout_condition_duration":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Payout Condition Duration"},"allocation_time_seconds":{"anyOf":[{"type":"integer","maximum":60.0,"minimum":1.0},{"type":"null"}],"title":"Allocation Time Seconds"},"rate_limit":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Rate Limit"},"rate_period":{"anyOf":[{"type":"string","enum":["min","hour","day"]},{"type":"null"}],"title":"Rate Period"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"receive_mode":{"anyOf":[{"type":"string","enum":["dynamic","static_standard","static_multi_bid"]},{"type":"null"}],"title":"Receive Mode"},"receive_number_id":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Receive Number Id"},"call_flow_id":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Call Flow Id"},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id","description":"External system ID for migration purposes"}},"additionalProperties":false,"type":"object","title":"InboundRtbPatch"},"InboundRtbRequestListRow":{"properties":{"request_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Request Id"},"inbound_rtb_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inbound Rtb Id"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"caller_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caller Id"},"total_routes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Routes"},"eligible_routes_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Eligible Routes Count"},"call_log_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Log Id"},"duration":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"publisher_payout":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Publisher Payout"},"target_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Number"},"buyer_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Id"},"campaign_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Campaign Id"},"campaign_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Campaign Name"},"publisher_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publisher Id"},"publisher_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publisher Name"},"buyer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Name"}},"additionalProperties":true,"type":"object","title":"InboundRtbRequestListRow"},"InboundRtbRequestParamRow":{"properties":{"request_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Request Id"},"param_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Param Key"},"param_value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Param Value"}},"additionalProperties":true,"type":"object","title":"InboundRtbRequestParamRow"},"InboundRtbRequestsListResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/InboundRtbRequestListRow"},"type":"array","title":"Data"},"meta":{"$ref":"#/components/schemas/PaginatedResponseMeta"}},"additionalProperties":false,"type":"object","required":["data","meta"],"title":"InboundRtbRequestsListResponse"},"InboundRtbResponse":{"properties":{"id":{"type":"integer","title":"Id"},"inbound_rtb_id":{"type":"string","title":"Inbound Rtb Id"},"campaign_id":{"type":"string","title":"Campaign Id"},"campaign_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Campaign Name"},"publisher_id":{"type":"string","title":"Publisher Id"},"publisher_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publisher Name"},"payout_mode":{"type":"string","title":"Payout Mode"},"payout_percentage":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Payout Percentage"},"duration_add_seconds":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Add Seconds"},"payout":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Payout"},"payout_condition":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payout Condition"},"payout_condition_duration":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Payout Condition Duration"},"allocation_time_seconds":{"type":"integer","title":"Allocation Time Seconds"},"rate_limit":{"type":"integer","title":"Rate Limit"},"rate_period":{"type":"string","title":"Rate Period"},"is_active":{"type":"boolean","title":"Is Active"},"receive_mode":{"type":"string","title":"Receive Mode","default":"dynamic"},"receive_number_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Receive Number Id"},"call_flow_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Flow Id"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"additionalProperties":false,"type":"object","required":["id","inbound_rtb_id","campaign_id","publisher_id","payout_mode","allocation_time_seconds","rate_limit","rate_period","is_active"],"title":"InboundRtbResponse"},"InboundRtbStatsSummaryResponse":{"properties":{"by_campaign":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"By Campaign"},"by_publisher":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"By Publisher"},"by_state":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"By State"},"by_buyer":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"By Buyer"}},"additionalProperties":false,"type":"object","required":["by_campaign","by_publisher","by_state","by_buyer"],"title":"InboundRtbStatsSummaryResponse"},"InboundRtbSummaryRequestBundle":{"properties":{"request":{"$ref":"#/components/schemas/InboundRtbSummaryRequestRow"},"params":{"items":{"$ref":"#/components/schemas/InboundRtbRequestParamRow"},"type":"array","title":"Params"}},"additionalProperties":false,"type":"object","required":["request","params"],"title":"InboundRtbSummaryRequestBundle"},"InboundRtbSummaryRequestRow":{"properties":{"request_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Request Id"},"inbound_rtb_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inbound Rtb Id"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"request_caller_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Request Caller Id"},"processing_time_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Processing Time Ms"},"call_log_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Log Id"},"buyer_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Id"},"buyer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Name"},"request_target_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Request Target Number"},"duration":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration"},"publisher_payout":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Publisher Payout"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"campaign_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Campaign Id"},"campaign_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Campaign Name"},"publisher_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publisher Id"},"publisher_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publisher Name"}},"additionalProperties":true,"type":"object","title":"InboundRtbSummaryRequestRow"},"InboundRtbSummaryRequestsListResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/InboundRtbSummaryRequestBundle"},"type":"array","title":"Data"},"meta":{"$ref":"#/components/schemas/PaginatedResponseMeta"}},"additionalProperties":false,"type":"object","required":["data","meta"],"title":"InboundRtbSummaryRequestsListResponse"},"IncomingWebhookCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"type":{"type":"string","enum":["call_data","update_revenue","update_tags","update_fields"],"title":"Type"},"lifespan":{"type":"integer","minimum":0.0,"title":"Lifespan","description":"Lifespan in seconds for call_data type","default":3600},"caller_id_match_days":{"type":"integer","maximum":7.0,"minimum":1.0,"title":"Caller Id Match Days","default":7},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id","description":"External system ID for migration purposes"}},"additionalProperties":false,"type":"object","required":["name","type"],"title":"IncomingWebhookCreate"},"IncomingWebhookListResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/IncomingWebhookResponse"},"type":"array","title":"Data"},"meta":{"$ref":"#/components/schemas/PaginatedResponseMeta"}},"additionalProperties":false,"type":"object","required":["data","meta"],"title":"IncomingWebhookListResponse"},"IncomingWebhookPatch":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"type":{"anyOf":[{"type":"string","enum":["call_data","update_revenue","update_tags","update_fields"]},{"type":"null"}],"title":"Type"},"lifespan":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Lifespan"},"caller_id_match_days":{"anyOf":[{"type":"integer","maximum":7.0,"minimum":1.0},{"type":"null"}],"title":"Caller Id Match Days"},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id"}},"additionalProperties":false,"type":"object","title":"IncomingWebhookPatch"},"IncomingWebhookRequest":{"properties":{"id":{"type":"string","title":"Id"},"incoming_webhook_config_id":{"type":"string","title":"Incoming Webhook Config Id"},"call_log_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Log Id"},"body":{"title":"Body"},"headers":{"title":"Headers"},"query_string":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Query String"},"method":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Method"},"path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Path"},"source_ip":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Ip"},"transaction_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Transaction Id"},"response_status_code":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Response Status Code"},"response_body":{"title":"Response Body"},"response_headers":{"title":"Response Headers"},"response_time_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Response Time Ms"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"webhook_config_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Webhook Config Name"},"webhook_config_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Webhook Config Type"}},"additionalProperties":false,"type":"object","required":["id","incoming_webhook_config_id"],"title":"IncomingWebhookRequest","description":"One incoming webhook delivery attempt (same fields as the legacy portal list)."},"IncomingWebhookRequestListResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/IncomingWebhookRequest"},"type":"array","title":"Data"},"meta":{"$ref":"#/components/schemas/PaginatedResponseMeta"}},"additionalProperties":false,"type":"object","required":["data","meta"],"title":"IncomingWebhookRequestListResponse"},"IncomingWebhookResponse":{"properties":{"id":{"type":"string","title":"Id"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"org_id":{"type":"string","title":"Org Id"},"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"type":{"type":"string","title":"Type"},"auth_key":{"type":"string","title":"Auth Key"},"lifespan":{"type":"integer","title":"Lifespan"},"caller_id_match_days":{"type":"integer","title":"Caller Id Match Days"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id"}},"additionalProperties":false,"type":"object","required":["id","org_id","name","type","auth_key","lifespan","caller_id_match_days"],"title":"IncomingWebhookResponse"},"LifeLogEvent":{"properties":{"id":{"type":"string","title":"Id"},"inbound_rtb_id":{"type":"string","title":"Inbound Rtb Id"},"request_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Request Id"},"event_time":{"type":"string","title":"Event Time"},"title":{"type":"string","title":"Title"},"details":{"additionalProperties":true,"type":"object","title":"Details"},"rtb_context":{"$ref":"#/components/schemas/LifeLogRtbContext"}},"additionalProperties":false,"type":"object","required":["id","inbound_rtb_id","event_time","title","rtb_context"],"title":"LifeLogEvent"},"LifeLogRtbContext":{"properties":{"campaign_name":{"type":"string","title":"Campaign Name"},"publisher_name":{"type":"string","title":"Publisher Name"}},"additionalProperties":false,"type":"object","required":["campaign_name","publisher_name"],"title":"LifeLogRtbContext"},"LifeLogsByRequestResponse":{"properties":{"events":{"items":{"$ref":"#/components/schemas/LifeLogEvent"},"type":"array","title":"Events"},"request_id":{"type":"string","title":"Request Id"},"summary":{"$ref":"#/components/schemas/LifeLogsSummary"}},"additionalProperties":false,"type":"object","required":["events","request_id","summary"],"title":"LifeLogsByRequestResponse"},"LifeLogsSummary":{"properties":{"total_events":{"type":"integer","title":"Total Events"},"unique_rtb_configs":{"type":"integer","title":"Unique Rtb Configs"}},"additionalProperties":false,"type":"object","required":["total_events","unique_rtb_configs"],"title":"LifeLogsSummary"},"MediaUploadResponse":{"properties":{"filePath":{"type":"string","title":"Filepath"},"bucketName":{"type":"string","title":"Bucketname"},"audioFileName":{"type":"string","title":"Audiofilename"},"hash":{"type":"string","pattern":"^[0-9a-f]{64}$","title":"Hash"}},"type":"object","required":["filePath","bucketName","audioFileName","hash"],"title":"MediaUploadResponse"},"NumberBuyRequest":{"properties":{"prefix":{"anyOf":[{"type":"string","maxLength":10},{"type":"null"}],"title":"Prefix","description":"Preferred NANP phone number prefix. Use a 3-digit local area code or a toll-free prefix (800, 888, 877, 866, 855, 844, 833). If omitted (and toll_free is false), the API picks one available local number at random.","examples":["919"]},"quantity":{"type":"integer","maximum":10.0,"minimum":1.0,"title":"Quantity","description":"How many numbers to purchase in this order (1–10).","default":1},"toll_free":{"type":"boolean","title":"Toll Free","description":"When true, order toll-free numbers. If prefix is omitted, uses 800. If prefix is set, it must be a toll-free NPA (800, 888, 877, 866, 855, 844, 833).","default":false},"imported":{"type":"boolean","title":"Imported","description":"Internal migration flag indicating this purchased Moja number maps to a number imported from another platform.","default":false},"imported_replaced_number":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Imported Replaced Number","description":"Original external-platform number that this Moja number will replace after porting."}},"additionalProperties":false,"type":"object","title":"NumberBuyRequest"},"NumberLabelRef":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"display_name":{"type":"string","title":"Display Name"}},"additionalProperties":false,"type":"object","required":["id","name","display_name"],"title":"NumberLabelRef"},"NumberListResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/NumberResponse"},"type":"array","title":"Data"},"meta":{"$ref":"#/components/schemas/PaginatedResponseMeta"}},"additionalProperties":false,"type":"object","required":["data","meta"],"title":"NumberListResponse"},"NumberOrderStatusDetail":{"properties":{"number_id":{"type":"string","title":"Number Id","description":"Unique identifier for the number"},"phone_number":{"type":"string","title":"Phone Number","description":"Phone number"},"order_status":{"type":"string","title":"Order Status","description":"Order status (COMPLETE, FAILED, RECEIVED, PENDING)"},"error_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Description","description":"Error description if number purchase failed"}},"additionalProperties":false,"type":"object","required":["number_id","phone_number","order_status"],"title":"NumberOrderStatusDetail"},"NumberPoolCreateRequest":{"properties":{"name":{"type":"string","maxLength":255,"minLength":3,"title":"Name","description":"Name of the number pool"},"country":{"$ref":"#/components/schemas/Country","description":"Country for the number pool"},"closed_browser_delay":{"anyOf":[{"type":"number","maximum":1440.0,"minimum":0.5},{"type":"null"}],"title":"Closed Browser Delay","description":"Delay in minutes before releasing number after browser close (up to 1 day, 0.5 min increments)","default":1},"browser_idle_limit":{"anyOf":[{"type":"number","maximum":2880.0,"minimum":1.0},{"type":"null"}],"title":"Browser Idle Limit","description":"Delay in minutes before releasing number after browser idle (up to 2 days, 0.5 min increments)","default":5},"size":{"type":"integer","maximum":10000.0,"minimum":1.0,"title":"Size","description":"Number of phone numbers to allocate to this number pool"},"number_type":{"$ref":"#/components/schemas/NumberType","description":"Type of numbers (toll_free or local)"},"prefix":{"anyOf":[{"type":"string","maxLength":10,"minLength":3},{"type":"null"}],"title":"Prefix","description":"Prefix for toll-free numbers"},"city":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"City","description":"City name for local numbers"},"state":{"anyOf":[{"type":"string","maxLength":2,"minLength":2},{"type":"null"}],"title":"State","description":"State code for local numbers"},"zip":{"anyOf":[{"type":"string","pattern":"^\\d{5}$"},{"type":"null"}],"title":"Zip","description":"ZIP code for local numbers"}},"additionalProperties":false,"type":"object","required":["name","country","size","number_type"],"title":"NumberPoolCreateRequest"},"NumberPoolDeleteResponse":{"properties":{"message":{"type":"string","title":"Message","description":"Delete result message"}},"additionalProperties":false,"type":"object","required":["message"],"title":"NumberPoolDeleteResponse"},"NumberPoolListResponse":{"properties":{"number_pools":{"items":{"$ref":"#/components/schemas/NumberPoolResponse"},"type":"array","title":"Number Pools","description":"List of number pools"},"total":{"type":"integer","title":"Total","description":"Total number of number pools"}},"additionalProperties":false,"type":"object","required":["number_pools","total"],"title":"NumberPoolListResponse"},"NumberPoolNumberResponse":{"properties":{"id":{"type":"integer","title":"Id","description":"Unique identifier for the entry in the number pool numbers table"},"number_pool_id":{"type":"string","title":"Number Pool Id","description":"Unique identifier for the number pool this number belongs to"},"number_id":{"type":"string","title":"Number Id","description":"Unique identifier for the number"},"phone_number":{"type":"string","title":"Phone Number","description":"Phone number"},"is_allocated":{"type":"boolean","title":"Is Allocated","description":"Whether the number is allocated"},"allocated_to_snippet_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Allocated To Snippet Id","description":"Snippet ID for campaign routing"},"allocated_to_visitor_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Allocated To Visitor Id","description":"Visitor ID for deduplication"},"allocated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Allocated At","description":"Time when the number was allocated"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At","description":"Expiration time for the allocated number"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Time when the number was created"}},"additionalProperties":false,"type":"object","required":["id","number_pool_id","number_id","phone_number","is_allocated","created_at"],"title":"NumberPoolNumberResponse"},"NumberPoolOrder":{"properties":{"id":{"type":"integer","title":"Id","description":"Unique identifier for the order record"},"number_pool_id":{"type":"string","title":"Number Pool Id","description":"Pool this order belongs to"},"bandwidth_order_id":{"type":"string","title":"Bandwidth Order Id","description":"Bandwidth order ID"},"order_type":{"type":"string","title":"Order Type","description":"Order type"},"order_status":{"type":"string","title":"Order Status","description":"Order status"},"numbers_requested":{"type":"integer","title":"Numbers Requested","description":"Number of numbers requested"},"numbers_provisioned":{"type":"integer","title":"Numbers Provisioned","description":"Number of numbers successfully provisioned"},"numbers_failed":{"type":"integer","title":"Numbers Failed","description":"Number of numbers that failed"},"error_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Description","description":"Error description if order failed"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"When the order was created"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"When the order was completed"}},"additionalProperties":false,"type":"object","required":["id","number_pool_id","bandwidth_order_id","order_type","order_status","numbers_requested","numbers_provisioned","numbers_failed","created_at"],"title":"NumberPoolOrder"},"NumberPoolOrderStatusResponse":{"properties":{"number_pool_id":{"type":"string","title":"Number Pool Id","description":"Unique identifier for the number pool"},"bandwidth_order_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bandwidth Order Id","description":"Bandwidth order ID"},"provisioning_status":{"type":"string","title":"Provisioning Status","description":"Overall pool provisioning status"},"provisioning_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provisioning Error","description":"Error description if pool provisioning failed"},"summary":{"additionalProperties":{"type":"integer"},"type":"object","title":"Summary","description":"Summary counts"},"numbers":{"items":{"$ref":"#/components/schemas/NumberOrderStatusDetail"},"type":"array","title":"Numbers","description":"Individual number statuses"}},"additionalProperties":false,"type":"object","required":["number_pool_id","provisioning_status","summary","numbers"],"title":"NumberPoolOrderStatusResponse"},"NumberPoolOrdersResponse":{"properties":{"number_pool_id":{"type":"string","title":"Number Pool Id","description":"Unique identifier for the number pool"},"orders":{"items":{"$ref":"#/components/schemas/NumberPoolOrder"},"type":"array","title":"Orders","description":"List of orders for this pool"},"total":{"type":"integer","title":"Total","description":"Total number of orders"}},"additionalProperties":false,"type":"object","required":["number_pool_id","orders","total"],"title":"NumberPoolOrdersResponse"},"NumberPoolResponse":{"properties":{"number_pool_id":{"type":"string","title":"Number Pool Id","description":"Unique identifier for the number pool"},"org_id":{"type":"string","title":"Org Id","description":"Unique identifier for the organization"},"name":{"type":"string","title":"Name","description":"Name of the number pool"},"country":{"$ref":"#/components/schemas/Country","description":"Country for the number pool"},"closed_browser_delay":{"type":"number","title":"Closed Browser Delay","description":"Delay in minutes before releasing number after browser close"},"browser_idle_limit":{"type":"number","title":"Browser Idle Limit","description":"Delay in minutes before releasing number after browser idle"},"size":{"type":"integer","title":"Size","description":"Number of phone numbers to allocate to this number pool"},"number_type":{"$ref":"#/components/schemas/NumberType","description":"Type of numbers (toll_free or local)"},"prefix":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prefix","description":"Prefix for toll-free numbers"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City","description":"City name for local numbers"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State","description":"State code for local numbers"},"zip":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Zip","description":"ZIP code for local numbers"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether the number pool is active"},"provisioning_status":{"type":"string","title":"Provisioning Status","description":"Overall pool provisioning status","default":"complete"},"has_pending_orders":{"type":"boolean","title":"Has Pending Orders","description":"Whether pool has pending expansion orders","default":false},"provisioning_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provisioning Error","description":"Latest provisioning error message if an order failed"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Time when the number pool was created"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Time when the number pool was last updated"},"deleted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Deleted At","description":"Time when the number pool was deleted"},"statistics":{"anyOf":[{"$ref":"#/components/schemas/NumberPoolStatisticsResponse"},{"type":"null"}],"description":"Statistics for the number pool"},"numbers":{"anyOf":[{"items":{"$ref":"#/components/schemas/NumberPoolNumberResponse"},"type":"array"},{"type":"null"}],"title":"Numbers","description":"Numbers in the number pool"}},"additionalProperties":false,"type":"object","required":["number_pool_id","org_id","name","country","closed_browser_delay","browser_idle_limit","size","number_type","is_active","created_at","updated_at"],"title":"NumberPoolResponse"},"NumberPoolStatisticsEnvelopeResponse":{"properties":{"number_pool_id":{"type":"string","title":"Number Pool Id","description":"Unique identifier for the number pool"},"statistics":{"$ref":"#/components/schemas/NumberPoolStatisticsResponse","description":"Statistics for the number pool"}},"additionalProperties":false,"type":"object","required":["number_pool_id","statistics"],"title":"NumberPoolStatisticsEnvelopeResponse"},"NumberPoolStatisticsResponse":{"properties":{"total_numbers":{"type":"integer","title":"Total Numbers","description":"Total number of numbers in the number pool"},"allocated_numbers":{"type":"integer","title":"Allocated Numbers","description":"Number of allocated numbers in the number pool"},"available_numbers":{"type":"integer","title":"Available Numbers","description":"Number of available numbers in the number pool"},"impressions_per_day":{"type":"integer","title":"Impressions Per Day","description":"Number of impressions per day"},"misses_per_day":{"type":"integer","title":"Misses Per Day","description":"Number of misses per day"},"impressions_per_month":{"type":"integer","title":"Impressions Per Month","description":"Number of impressions per month"},"misses_per_month":{"type":"integer","title":"Misses Per Month","description":"Number of misses per month"},"utilization_rate":{"type":"number","title":"Utilization Rate","description":"Utilization rate of the number pool"}},"additionalProperties":false,"type":"object","required":["total_numbers","allocated_numbers","available_numbers","impressions_per_day","misses_per_day","impressions_per_month","misses_per_month","utilization_rate"],"title":"NumberPoolStatisticsResponse"},"NumberPoolUpdateRequest":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255,"minLength":3},{"type":"null"}],"title":"Name","description":"Name of the number pool"},"closed_browser_delay":{"anyOf":[{"type":"number","maximum":1440.0,"minimum":0.5},{"type":"null"}],"title":"Closed Browser Delay","description":"Delay in minutes before releasing number after browser close (up to 1 day, 0.5 min increments)"},"browser_idle_limit":{"anyOf":[{"type":"number","maximum":2880.0,"minimum":1.0},{"type":"null"}],"title":"Browser Idle Limit","description":"Delay in minutes before releasing number after browser idle (up to 2 days, 0.5 min increments)"},"size":{"anyOf":[{"type":"integer","maximum":10000.0,"minimum":1.0},{"type":"null"}],"title":"Size","description":"New size for the number pool"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active","description":"Whether the number pool is active"}},"additionalProperties":false,"type":"object","title":"NumberPoolUpdateRequest"},"NumberResponse":{"properties":{"id":{"type":"string","title":"Id"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"number_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Number Id"},"org_id":{"type":"string","title":"Org Id"},"number":{"type":"string","title":"Number"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"labels":{"items":{"$ref":"#/components/schemas/NumberLabelRef"},"type":"array","title":"Labels"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"site_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Id"},"order_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Order Status"},"final_destination_uri":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Final Destination Uri"},"campaign_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Campaign Id"},"campaign":{"anyOf":[{"$ref":"#/components/schemas/ResourceRef"},{"type":"null"}]},"publisher_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publisher Id"},"publisher":{"anyOf":[{"$ref":"#/components/schemas/ResourceRef"},{"type":"null"}]},"phone_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone Type"},"hourly":{"type":"integer","title":"Hourly","default":0},"daily":{"type":"integer","title":"Daily","default":0},"weekly":{"type":"integer","title":"Weekly","default":0},"monthly":{"type":"integer","title":"Monthly","default":0},"yearly":{"type":"integer","title":"Yearly","default":0},"total":{"type":"integer","title":"Total","default":0},"payout":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Payout"},"payout_condition":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payout Condition"},"payout_condition_duration":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Payout Condition Duration"},"provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider"},"is_active":{"type":"boolean","title":"Is Active","default":true},"order_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Order Date"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id"},"imported":{"type":"boolean","title":"Imported","default":false},"imported_replaced_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Imported Replaced Number"}},"additionalProperties":false,"type":"object","required":["id","org_id","number"],"title":"NumberResponse"},"NumberType":{"type":"string","enum":["local","toll_free"],"title":"NumberType"},"OutboundRtbRequestListRow":{"properties":{"request_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Request Id"},"rtb_group_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rtb Group Id"},"group_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Group Name"},"rtb_formula_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rtb Formula Id"},"call_log_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Log Id"},"inbound_rtb_request_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inbound Rtb Request Id"},"caller_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caller Id"},"winning_rtb":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Winning Rtb"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"http_status":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Http Status"},"outcome":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outcome"},"outcome_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outcome Reason"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"},"payout":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Payout"},"campaign_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Campaign Id"},"campaign_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Campaign Name"},"publisher_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publisher Id"},"publisher_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publisher Name"},"buyer_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Id"},"buyer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Name"},"start_time":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start Time"},"end_time":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End Time"}},"additionalProperties":true,"type":"object","title":"OutboundRtbRequestListRow"},"OutboundRtbRequestStepsResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/OutboundRtbStepRow"},"type":"array","title":"Data"}},"additionalProperties":false,"type":"object","required":["data"],"title":"OutboundRtbRequestStepsResponse"},"OutboundRtbRequestsListResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/OutboundRtbRequestListRow"},"type":"array","title":"Data"},"meta":{"$ref":"#/components/schemas/PaginatedResponseMeta"}},"additionalProperties":false,"type":"object","required":["data","meta"],"title":"OutboundRtbRequestsListResponse"},"OutboundRtbStatsSummaryResponse":{"properties":{"by_campaign":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"By Campaign"},"by_publisher":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"By Publisher"},"by_state":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"By State"},"by_buyer":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"By Buyer"},"by_rtb_group":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"By Rtb Group"},"by_rtb_group_buyer":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"By Rtb Group Buyer"}},"additionalProperties":false,"type":"object","required":["by_campaign","by_publisher","by_state","by_buyer","by_rtb_group","by_rtb_group_buyer"],"title":"OutboundRtbStatsSummaryResponse"},"OutboundRtbStepRow":{"properties":{"request_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Request Id"},"rtb_request_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rtb Request Id"},"step_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Step Url"},"step_method":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Step Method"},"step_start_time":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Step Start Time"},"step_end_time":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Step End Time"},"config":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Config"},"response_data":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Response Data"},"response_code":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Response Code"},"response_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Response Error"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"additionalProperties":true,"type":"object","title":"OutboundRtbStepRow"},"OutgoingWebhookCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"event_type_id":{"type":"string","minLength":1,"title":"Event Type Id"},"url":{"type":"string","maxLength":500,"minLength":1,"title":"Url"},"method":{"type":"string","enum":["GET","POST","PUT","PATCH","DELETE"],"title":"Method","default":"POST"},"params":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Params"},"headers":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Headers"},"body":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Body"},"body_type":{"type":"string","enum":["json","form_data"],"title":"Body Type","default":"json"},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id","description":"External system ID for migration purposes"}},"additionalProperties":false,"type":"object","required":["name","event_type_id","url"],"title":"OutgoingWebhookCreate"},"OutgoingWebhookEventType":{"properties":{"id":{"type":"string","title":"Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"internal_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Internal Name"}},"additionalProperties":false,"type":"object","required":["id"],"title":"OutgoingWebhookEventType"},"OutgoingWebhookListResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/OutgoingWebhookResponse"},"type":"array","title":"Data"},"meta":{"$ref":"#/components/schemas/PaginatedResponseMeta"}},"additionalProperties":false,"type":"object","required":["data","meta"],"title":"OutgoingWebhookListResponse"},"OutgoingWebhookPatch":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"event_type_id":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}],"title":"Event Type Id"},"url":{"anyOf":[{"type":"string","maxLength":500,"minLength":1},{"type":"null"}],"title":"Url"},"method":{"anyOf":[{"type":"string","enum":["GET","POST","PUT","PATCH","DELETE"]},{"type":"null"}],"title":"Method"},"params":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Params"},"headers":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Headers"},"body":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Body"},"body_type":{"anyOf":[{"type":"string","enum":["json","form_data"]},{"type":"null"}],"title":"Body Type"},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id"}},"additionalProperties":false,"type":"object","title":"OutgoingWebhookPatch"},"OutgoingWebhookRequest":{"properties":{"id":{"type":"string","title":"Id"},"outgoing_webhook_config_id":{"type":"string","title":"Outgoing Webhook Config Id"},"body":{"title":"Body"},"headers":{"title":"Headers"},"query_string":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Query String"},"method":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Method"},"path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Path"},"source_ip":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Ip"},"response_status_code":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Response Status Code"},"response_body":{"title":"Response Body"},"response_headers":{"title":"Response Headers"},"response_time_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Response Time Ms"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"webhook_config_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Webhook Config Name"},"event_type_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Event Type Id"},"event_type":{"anyOf":[{"$ref":"#/components/schemas/OutgoingWebhookEventType"},{"type":"null"}]}},"additionalProperties":false,"type":"object","required":["id","outgoing_webhook_config_id"],"title":"OutgoingWebhookRequest","description":"One outgoing webhook delivery attempt (same fields as the legacy portal list)."},"OutgoingWebhookRequestListResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/OutgoingWebhookRequest"},"type":"array","title":"Data"},"meta":{"$ref":"#/components/schemas/PaginatedResponseMeta"}},"additionalProperties":false,"type":"object","required":["data","meta"],"title":"OutgoingWebhookRequestListResponse"},"OutgoingWebhookResponse":{"properties":{"id":{"type":"string","title":"Id"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"org_id":{"type":"string","title":"Org Id"},"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"event_type_id":{"type":"string","title":"Event Type Id"},"event_type":{"anyOf":[{"$ref":"#/components/schemas/EventTypeResponse"},{"type":"null"}]},"url":{"type":"string","title":"Url"},"method":{"type":"string","title":"Method"},"params":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Params"},"headers":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Headers"},"body":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Body"},"body_type":{"type":"string","title":"Body Type"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id"}},"additionalProperties":false,"type":"object","required":["id","org_id","name","event_type_id","url","method","body_type"],"title":"OutgoingWebhookResponse"},"PaginatedResponseMeta":{"properties":{"limit":{"type":"integer","title":"Limit"},"offset":{"type":"integer","title":"Offset"},"count":{"type":"integer","title":"Count"},"total":{"type":"integer","title":"Total"},"has_more":{"type":"boolean","title":"Has More"},"next_offset":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Next Offset"},"previous_offset":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Previous Offset"}},"additionalProperties":false,"type":"object","required":["limit","offset","count","total","has_more"],"title":"PaginatedResponseMeta"},"PausableEntitiesResponse":{"properties":{"entities":{"items":{"$ref":"#/components/schemas/PausableEntity"},"type":"array","title":"Entities"}},"additionalProperties":false,"type":"object","required":["entities"],"title":"PausableEntitiesResponse"},"PausableEntity":{"properties":{"type":{"type":"string","enum":["target","rtb"],"title":"Type"},"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"is_active":{"type":"boolean","title":"Is Active"},"is_paused":{"type":"boolean","title":"Is Paused"},"paused_until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Paused Until"}},"additionalProperties":false,"type":"object","required":["type","id","name","is_active","is_paused"],"title":"PausableEntity"},"PauseItemRef":{"properties":{"type":{"type":"string","enum":["target","rtb"],"title":"Type"},"id":{"type":"string","minLength":1,"title":"Id"}},"additionalProperties":false,"type":"object","required":["type","id"],"title":"PauseItemRef"},"PauseRequest":{"properties":{"duration_minutes":{"anyOf":[{"type":"integer","maximum":43200.0,"minimum":1.0},{"type":"null"}],"title":"Duration Minutes"},"paused_until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Paused Until"},"unlimited":{"type":"boolean","title":"Unlimited","default":false}},"additionalProperties":false,"type":"object","title":"PauseRequest"},"PublisherCreate":{"properties":{"name":{"type":"string","minLength":1,"title":"Name"},"street_address":{"type":"string","title":"Street Address"},"city":{"type":"string","title":"City"},"state":{"type":"string","title":"State"},"zip_code":{"type":"string","title":"Zip Code"},"country":{"type":"string","title":"Country"},"phone_number":{"type":"string","title":"Phone Number"},"email":{"type":"string","title":"Email","default":""},"website":{"type":"string","title":"Website","default":""},"timezone":{"type":"string","title":"Timezone","default":"America/New_York"},"block_calls_if_capped":{"type":"boolean","title":"Block Calls If Capped"},"access_to_call_recordings":{"type":"boolean","title":"Access To Call Recordings"},"disable_recordings":{"type":"boolean","title":"Disable Recordings","default":false},"is_active":{"type":"boolean","title":"Is Active"},"advanced_caps":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Advanced Caps"},"everflow_affiliate_id":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Everflow Affiliate Id"},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id","description":"External system ID for migration purposes"}},"additionalProperties":false,"type":"object","required":["name","street_address","city","state","zip_code","country","phone_number","block_calls_if_capped","access_to_call_recordings","is_active"],"title":"PublisherCreate"},"PublisherListResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/PublisherResponse"},"type":"array","title":"Data"},"meta":{"$ref":"#/components/schemas/PaginatedResponseMeta"}},"additionalProperties":false,"type":"object","required":["data","meta"],"title":"PublisherListResponse"},"PublisherPatch":{"properties":{"name":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}],"title":"Name"},"street_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Street Address"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"},"zip_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Zip Code"},"country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Country"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone Number"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"website":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website"},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone"},"block_calls_if_capped":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Block Calls If Capped"},"access_to_call_recordings":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Access To Call Recordings"},"disable_recordings":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Disable Recordings"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"advanced_caps":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Advanced Caps"},"everflow_affiliate_id":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Everflow Affiliate Id"},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id","description":"External system ID for migration purposes"}},"additionalProperties":false,"type":"object","title":"PublisherPatch"},"PublisherResponse":{"properties":{"id":{"type":"string","title":"Id"},"org_id":{"type":"string","title":"Org Id"},"name":{"type":"string","title":"Name"},"street_address":{"type":"string","title":"Street Address"},"city":{"type":"string","title":"City"},"state":{"type":"string","title":"State"},"zip_code":{"type":"string","title":"Zip Code"},"country":{"type":"string","title":"Country"},"phone_number":{"type":"string","title":"Phone Number"},"email":{"type":"string","title":"Email"},"website":{"type":"string","title":"Website"},"timezone":{"type":"string","title":"Timezone"},"block_calls_if_capped":{"type":"boolean","title":"Block Calls If Capped"},"access_to_call_recordings":{"type":"boolean","title":"Access To Call Recordings"},"disable_recordings":{"type":"boolean","title":"Disable Recordings","default":false},"is_active":{"type":"boolean","title":"Is Active"},"hourly":{"type":"integer","title":"Hourly","default":0},"daily":{"type":"integer","title":"Daily","default":0},"weekly":{"type":"integer","title":"Weekly","default":0},"monthly":{"type":"integer","title":"Monthly","default":0},"yearly":{"type":"integer","title":"Yearly","default":0},"total":{"type":"integer","title":"Total","default":0},"everflow_affiliate_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Everflow Affiliate Id"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"advanced_caps":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Advanced Caps"}},"additionalProperties":false,"type":"object","required":["id","org_id","name","street_address","city","state","zip_code","country","phone_number","email","website","timezone","block_calls_if_capped","access_to_call_recordings","is_active"],"title":"PublisherResponse"},"RTBCreate":{"properties":{"rtb_name":{"type":"string","maxLength":255,"minLength":1,"title":"Rtb Name"},"buyer_id":{"type":"string","minLength":1,"title":"Buyer Id"},"rtb_type":{"type":"string","title":"Rtb Type","default":"dynamic"},"static_phone_number":{"type":"string","title":"Static Phone Number","default":""},"use_static_phone_number":{"type":"boolean","title":"Use Static Phone Number","default":false},"steps":{"items":{"$ref":"#/components/schemas/RTBStep"},"type":"array","minItems":1,"title":"Steps"},"mapped_response":{"additionalProperties":true,"type":"object","title":"Mapped Response","examples":[{"bid":"data.bid","duration":"data.duration","phone_number":"data.phoneNumber"}]},"zip_code_type":{"type":"string","title":"Zip Code Type","default":"dynamic"},"static_zip_code":{"type":"string","title":"Static Zip Code","default":""},"caller_id_param":{"type":"string","title":"Caller Id Param","default":""},"zip_code_param":{"type":"string","title":"Zip Code Param","default":""},"caller_id_test":{"type":"string","title":"Caller Id Test","default":""},"misc_settings":{"additionalProperties":true,"type":"object","title":"Misc Settings","examples":[{"retryCount":2,"timeoutMs":5000}]},"parsing_formula":{"additionalProperties":true,"type":"object","title":"Parsing Formula","examples":[{"parseInstructions":{"duration":"data.duration","payout":"data.bid","phoneNumber":"data.phoneNumber"}}]},"hours_of_operation":{"additionalProperties":true,"type":"object","title":"Hours Of Operation","examples":[{"always_open":true,"days":[]}]},"timezone":{"type":"string","title":"Timezone"},"is_active":{"type":"boolean","title":"Is Active","default":false},"max_concurrency":{"type":"integer","minimum":0.0,"title":"Max Concurrency","default":0},"consider_duplicate":{"type":"boolean","title":"Consider Duplicate","default":false},"consider_duplicate_on":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Consider Duplicate On"},"consider_duplicate_length":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Consider Duplicate Length"},"consider_duplicate_interval":{"type":"integer","minimum":1.0,"title":"Consider Duplicate Interval","description":"Lookback window in days for the consider-duplicate check","default":30},"conversion_scope":{"type":"integer","minimum":0.0,"title":"Conversion Scope","default":10},"duplicate_conversion_action":{"type":"string","enum":["decline","route_no_pay","route_no_revenue","route_no_revenue_no_pay"],"title":"Duplicate Conversion Action","default":"decline"},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","examples":[{"enabled":true,"groups":[{"conditions":[{"field":"state","operator":"in","values":["CA","TX"]}]}]}]},"rtb_timeout":{"type":"integer","maximum":30000.0,"minimum":1000.0,"title":"Rtb Timeout","default":5000},"outbound_ping_rate_limit":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Outbound Ping Rate Limit"},"outbound_ping_rate_period":{"anyOf":[{"type":"string","enum":["min","hour","day"]},{"type":"null"}],"title":"Outbound Ping Rate Period"},"outbound_ping_max_inflight":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Outbound Ping Max Inflight"},"outbound_ping_backoff_enabled":{"type":"boolean","title":"Outbound Ping Backoff Enabled","default":false},"outbound_ping_backoff_threshold":{"type":"integer","minimum":1.0,"title":"Outbound Ping Backoff Threshold","default":3},"outbound_ping_backoff_seconds":{"type":"integer","minimum":1.0,"title":"Outbound Ping Backoff Seconds","default":60},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id","description":"External system ID for migration purposes"},"disable_recordings":{"type":"boolean","title":"Disable Recordings","default":false},"access_to_call_recordings":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Access To Call Recordings"},"advanced_caps":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Advanced Caps"}},"additionalProperties":false,"type":"object","required":["rtb_name","buyer_id","steps","mapped_response","parsing_formula","hours_of_operation","timezone"],"title":"RTBCreate"},"RTBGroupCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"minimum_bid":{"type":"number","minimum":0.0,"title":"Minimum Bid","default":0.0},"ping_timeout":{"type":"integer","maximum":30000.0,"minimum":1.0,"title":"Ping Timeout","description":"Ping timeout in milliseconds","default":5000},"predictive_routing_enabled":{"type":"boolean","title":"Predictive Routing Enabled","default":false},"predictive_routing_plan_id":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}],"title":"Predictive Routing Plan Id"},"minimum_call_count":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Minimum Call Count"},"desired_hours":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Desired Hours"},"underperforming_percentage":{"anyOf":[{"type":"number","maximum":100.0,"minimum":0.0},{"type":"null"}],"title":"Underperforming Percentage"},"rtb_formulas":{"items":{"$ref":"#/components/schemas/RTBGroupFormulaInput"},"type":"array","minItems":1,"title":"Rtb Formulas"},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id","description":"External system ID for migration purposes"}},"additionalProperties":false,"type":"object","required":["name","rtb_formulas"],"title":"RTBGroupCreate"},"RTBGroupFormulaInput":{"properties":{"rtb_formula_id":{"type":"string","minLength":1,"title":"Rtb Formula Id"},"maximum_bid_per_target":{"type":"number","minimum":0.0,"title":"Maximum Bid Per Target","default":0.0},"minimum_bid_per_target":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Minimum Bid Per Target","description":"Per-target minimum/floor bid override. null = inherit RTB group default."},"ping_timeout_per_target":{"anyOf":[{"type":"integer","maximum":30000.0,"minimum":1.0},{"type":"null"}],"title":"Ping Timeout Per Target","description":"Per-target ping timeout override (ms). null = inherit RTB group default."},"routing_modifier":{"type":"integer","maximum":10.0,"minimum":-10.0,"title":"Routing Modifier","description":"Legacy strategic routing modifier (-10..+10). Prefer routing_modifier_type/value for new clients.","default":0},"routing_modifier_type":{"type":"string","enum":["percentage","amount"],"title":"Routing Modifier Type","description":"How routing_modifier_value affects the predictive routing score. Routing-only; does not change payout.","default":"percentage"},"routing_modifier_value":{"type":"number","maximum":1000.0,"minimum":-1000.0,"title":"Routing Modifier Value","description":"Thumb-on-scale value. percentage = relative percent points, amount = fixed dollar value added to score.","default":0.0}},"additionalProperties":false,"type":"object","required":["rtb_formula_id"],"title":"RTBGroupFormulaInput","description":"Input schema for RTB formula relationship when creating/updating an RTB group."},"RTBGroupFormulaResponse":{"properties":{"id":{"type":"string","title":"Id"},"rtb_formula_id":{"type":"string","title":"Rtb Formula Id"},"rtb_formula":{"anyOf":[{"$ref":"#/components/schemas/ResourceRef"},{"type":"null"}]},"maximum_bid_per_target":{"type":"number","title":"Maximum Bid Per Target"},"minimum_bid_per_target":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Minimum Bid Per Target"},"ping_timeout_per_target":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Ping Timeout Per Target"},"routing_modifier":{"type":"integer","title":"Routing Modifier","default":0},"routing_modifier_type":{"type":"string","enum":["percentage","amount"],"title":"Routing Modifier Type","default":"percentage"},"routing_modifier_value":{"type":"number","title":"Routing Modifier Value","default":0.0}},"additionalProperties":false,"type":"object","required":["id","rtb_formula_id","maximum_bid_per_target"],"title":"RTBGroupFormulaResponse","description":"Response schema for RTB formula relationship."},"RTBGroupListResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/RTBGroupResponse"},"type":"array","title":"Data"},"meta":{"$ref":"#/components/schemas/PaginatedResponseMeta"}},"additionalProperties":false,"type":"object","required":["data","meta"],"title":"RTBGroupListResponse"},"RTBGroupPatch":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Name"},"minimum_bid":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Minimum Bid"},"ping_timeout":{"anyOf":[{"type":"integer","maximum":30000.0,"minimum":1.0},{"type":"null"}],"title":"Ping Timeout","description":"Ping timeout in milliseconds"},"predictive_routing_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Predictive Routing Enabled"},"predictive_routing_plan_id":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}],"title":"Predictive Routing Plan Id"},"minimum_call_count":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Minimum Call Count"},"desired_hours":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Desired Hours"},"underperforming_percentage":{"anyOf":[{"type":"number","maximum":100.0,"minimum":0.0},{"type":"null"}],"title":"Underperforming Percentage"},"rtb_formulas":{"anyOf":[{"items":{"$ref":"#/components/schemas/RTBGroupFormulaInput"},"type":"array","minItems":1},{"type":"null"}],"title":"Rtb Formulas"},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id","description":"External system ID for migration purposes"}},"additionalProperties":false,"type":"object","title":"RTBGroupPatch"},"RTBGroupResponse":{"properties":{"id":{"type":"string","title":"Id"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"org_id":{"type":"string","title":"Org Id"},"name":{"type":"string","title":"Name"},"minimum_bid":{"type":"number","title":"Minimum Bid"},"ping_timeout":{"type":"integer","title":"Ping Timeout"},"predictive_routing_enabled":{"type":"boolean","title":"Predictive Routing Enabled","default":false},"predictive_routing_plan_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Predictive Routing Plan Id"},"minimum_call_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Minimum Call Count"},"desired_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Desired Hours"},"underperforming_percentage":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Underperforming Percentage"},"rtb_formulas":{"items":{"$ref":"#/components/schemas/RTBGroupFormulaResponse"},"type":"array","title":"Rtb Formulas"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id"}},"additionalProperties":false,"type":"object","required":["id","org_id","name","minimum_bid","ping_timeout"],"title":"RTBGroupResponse"},"RTBListResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/RTBResponse"},"type":"array","title":"Data"},"meta":{"$ref":"#/components/schemas/PaginatedResponseMeta"}},"additionalProperties":false,"type":"object","required":["data","meta"],"title":"RTBListResponse"},"RTBPatch":{"properties":{"rtb_name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Rtb Name"},"buyer_id":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}],"title":"Buyer Id"},"rtb_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rtb Type"},"static_phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Static Phone Number"},"use_static_phone_number":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Use Static Phone Number"},"steps":{"anyOf":[{"items":{"$ref":"#/components/schemas/RTBStep"},"type":"array","minItems":1},{"type":"null"}],"title":"Steps"},"mapped_response":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Mapped Response","examples":[{"bid":"data.bid","duration":"data.duration","phone_number":"data.phoneNumber"}]},"zip_code_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Zip Code Type"},"static_zip_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Static Zip Code"},"caller_id_param":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caller Id Param"},"zip_code_param":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Zip Code Param"},"caller_id_test":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caller Id Test"},"misc_settings":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Misc Settings","examples":[{"retryCount":2,"timeoutMs":5000}]},"parsing_formula":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Parsing Formula","examples":[{"parseInstructions":{"duration":"data.duration","payout":"data.bid","phoneNumber":"data.phoneNumber"}}]},"hours_of_operation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Hours Of Operation","examples":[{"always_open":true,"days":[]}]},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"max_concurrency":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Max Concurrency"},"consider_duplicate":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Consider Duplicate"},"consider_duplicate_on":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Consider Duplicate On"},"consider_duplicate_length":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Consider Duplicate Length"},"consider_duplicate_interval":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Consider Duplicate Interval","description":"Lookback window in days for the consider-duplicate check"},"conversion_scope":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Conversion Scope"},"duplicate_conversion_action":{"anyOf":[{"type":"string","enum":["decline","route_no_pay","route_no_revenue","route_no_revenue_no_pay"]},{"type":"null"}],"title":"Duplicate Conversion Action"},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","examples":[{"enabled":true,"groups":[{"conditions":[{"field":"state","operator":"in","values":["CA","TX"]}]}]}]},"rtb_timeout":{"anyOf":[{"type":"integer","maximum":30000.0,"minimum":1.0},{"type":"null"}],"title":"Rtb Timeout"},"outbound_ping_rate_limit":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Outbound Ping Rate Limit"},"outbound_ping_rate_period":{"anyOf":[{"type":"string","enum":["min","hour","day"]},{"type":"null"}],"title":"Outbound Ping Rate Period"},"outbound_ping_max_inflight":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Outbound Ping Max Inflight"},"outbound_ping_backoff_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Outbound Ping Backoff Enabled"},"outbound_ping_backoff_threshold":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Outbound Ping Backoff Threshold"},"outbound_ping_backoff_seconds":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Outbound Ping Backoff Seconds"},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id","description":"External system ID for migration purposes"},"disable_recordings":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Disable Recordings"},"access_to_call_recordings":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Access To Call Recordings"},"advanced_caps":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Advanced Caps"}},"additionalProperties":false,"type":"object","title":"RTBPatch"},"RTBResponse":{"properties":{"id":{"type":"string","title":"Id"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"org_id":{"type":"string","title":"Org Id"},"buyer_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Id"},"buyer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Name"},"rtb_name":{"type":"string","title":"Rtb Name"},"rtb_type":{"type":"string","title":"Rtb Type"},"static_phone_number":{"type":"string","title":"Static Phone Number","default":""},"use_static_phone_number":{"type":"boolean","title":"Use Static Phone Number","default":false},"steps":{"items":{"$ref":"#/components/schemas/RTBStep"},"type":"array","title":"Steps"},"mapped_response":{"additionalProperties":true,"type":"object","title":"Mapped Response","examples":[{"bid":"data.bid","duration":"data.duration","phone_number":"data.phoneNumber"}]},"zip_code_type":{"type":"string","title":"Zip Code Type","default":"dynamic"},"static_zip_code":{"type":"string","title":"Static Zip Code","default":""},"caller_id_param":{"type":"string","title":"Caller Id Param","default":""},"zip_code_param":{"type":"string","title":"Zip Code Param","default":""},"caller_id_test":{"type":"string","title":"Caller Id Test","default":""},"misc_settings":{"additionalProperties":true,"type":"object","title":"Misc Settings","examples":[{"retryCount":2,"timeoutMs":5000}]},"parsing_formula":{"additionalProperties":true,"type":"object","title":"Parsing Formula","examples":[{"parseInstructions":{"duration":"data.duration","payout":"data.bid","phoneNumber":"data.phoneNumber"}}]},"hours_of_operation":{"additionalProperties":true,"type":"object","title":"Hours Of Operation","examples":[{"always_open":true,"days":[]}]},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone"},"is_active":{"type":"boolean","title":"Is Active"},"max_concurrency":{"type":"integer","title":"Max Concurrency","default":0},"consider_duplicate":{"type":"boolean","title":"Consider Duplicate","default":false},"consider_duplicate_on":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Consider Duplicate On"},"consider_duplicate_length":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Consider Duplicate Length"},"consider_duplicate_interval":{"type":"integer","title":"Consider Duplicate Interval","default":30},"conversion_scope":{"type":"integer","title":"Conversion Scope"},"duplicate_conversion_action":{"type":"string","enum":["decline","route_no_pay","route_no_revenue","route_no_revenue_no_pay"],"title":"Duplicate Conversion Action","default":"decline"},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","examples":[{"enabled":true,"groups":[{"conditions":[{"field":"state","operator":"in","values":["CA","TX"]}]}]}]},"rtb_timeout":{"type":"integer","title":"Rtb Timeout","default":5000},"outbound_ping_rate_limit":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Outbound Ping Rate Limit"},"outbound_ping_rate_period":{"anyOf":[{"type":"string","enum":["min","hour","day"]},{"type":"null"}],"title":"Outbound Ping Rate Period"},"outbound_ping_max_inflight":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Outbound Ping Max Inflight"},"outbound_ping_backoff_enabled":{"type":"boolean","title":"Outbound Ping Backoff Enabled","default":false},"outbound_ping_backoff_threshold":{"type":"integer","title":"Outbound Ping Backoff Threshold","default":3},"outbound_ping_backoff_seconds":{"type":"integer","title":"Outbound Ping Backoff Seconds","default":60},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id"},"disable_recordings":{"type":"boolean","title":"Disable Recordings","default":false},"access_to_call_recordings":{"type":"boolean","title":"Access To Call Recordings"},"advanced_caps":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Advanced Caps"},"paused_until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Paused Until"},"paused_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Paused At"},"paused_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Paused By"},"is_paused":{"type":"boolean","title":"Is Paused","default":false}},"additionalProperties":false,"type":"object","required":["id","org_id","rtb_name","rtb_type","is_active","conversion_scope","access_to_call_recordings"],"title":"RTBResponse"},"RTBStep":{"properties":{"url":{"type":"string","title":"Url"},"method":{"type":"string","title":"Method"},"headers":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Headers","examples":[[{"key":"Authorization","value":"Bearer token-123"}]]},"query_params":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Query Params","examples":[[{"key":"caller_id","value":"{{caller_id}}"}]]},"body_params":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Body Params","examples":[[{"key":"zip_code","value":"{{zip_code}}"}]]},"body_type":{"type":"string","title":"Body Type","default":"none"},"raw_body":{"type":"string","title":"Raw Body","default":""},"api_response":{"title":"Api Response","examples":[{"bid":12.5,"duration":90,"phoneNumber":"+15551234567"}]},"run_on_rtb_group_win":{"type":"boolean","title":"Run On Rtb Group Win","default":false},"selected_keys":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Selected Keys","examples":[[{"key":"bid","path":"data.bid"}]]},"response_field_mappings":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Response Field Mappings","examples":[[{"fieldPath":"data.bid","stepIndex":0,"tagName":"bid"}]]},"continue_on_failure":{"type":"boolean","title":"Continue On Failure","default":false},"processed_response":{"title":"Processed Response","default":"","examples":[{"bid":12.5,"duration":90,"phoneNumber":"+15551234567"}]},"process_response_code":{"type":"string","title":"Process Response Code","default":""},"target_selection_criteria":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Target Selection Criteria"}},"additionalProperties":false,"type":"object","required":["url","method","api_response"],"title":"RTBStep"},"ReportingBulkPayoutAdjustRequest":{"properties":{"call_log_ids":{"items":{"type":"string"},"type":"array","maxItems":500,"minItems":1,"title":"Call Log Ids","description":"Call log row IDs (same ids as returned by reporting queries). Maximum 500 per request."},"revenue_paid_out":{"anyOf":[{"type":"number"},{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$"},{"type":"null"}],"title":"Revenue Paid Out","description":"If set, revenue paid out applied to every call log id in call_log_ids."},"publisher_paid_out":{"anyOf":[{"type":"number"},{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$"},{"type":"null"}],"title":"Publisher Paid Out","description":"If set, publisher payout applied to every call log id in call_log_ids."}},"additionalProperties":false,"type":"object","required":["call_log_ids"],"title":"ReportingBulkPayoutAdjustRequest","description":"Bulk-adjust revenue_paid_out and/or publisher_paid_out for many call logs (same amount(s) on each row)."},"ReportingBulkPayoutAdjustResponse":{"properties":{"message":{"type":"string","title":"Message"},"updated_count":{"type":"integer","title":"Updated Count"},"requested_count":{"type":"integer","title":"Requested Count"},"revenue_paid_out":{"anyOf":[{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$"},{"type":"null"}],"title":"Revenue Paid Out"},"publisher_paid_out":{"anyOf":[{"type":"string","pattern":"^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$"},{"type":"null"}],"title":"Publisher Paid Out"},"failed_call_log_ids":{"items":{"type":"string"},"type":"array","title":"Failed Call Log Ids","description":"Call log ids from the request that were not found for your organization (no row updated). Empty when every requested id matched a call log."}},"additionalProperties":false,"type":"object","required":["message","updated_count","requested_count"],"title":"ReportingBulkPayoutAdjustResponse"},"ReportingCallsQueryRequest":{"properties":{"start_date":{"type":"string","title":"Start Date","description":"Inclusive range start (ISO 8601 date or datetime, UTC). Matches effective_call_time."},"end_date":{"type":"string","title":"End Date","description":"Inclusive range end (ISO 8601 date or datetime, UTC). Matches effective_call_time."},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone","description":"IANA timezone for custom_query date rules and summary date grouping (e.g. America/New_York)."},"campaign_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Campaign Id","description":"Restrict to this campaign id."},"publisher_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publisher Id","description":"Restrict to this publisher id."},"buyer_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Id","description":"Restrict to this buyer id."},"routing_plan_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Routing Plan Id","description":"Restrict to this routing plan id."},"dial_type_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dial Type Id","description":"Restrict to this dial target / RTB / target id (maps to dial_type_id on the call)."},"dialed_target":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dialed Target","description":"Restrict to dialed destination number."},"inbound_from":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inbound From","description":"Caller ID (ANI) filter."},"inbound_to":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inbound To","description":"Dialed publisher number filter."},"disposition":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Disposition","description":"QAI disposition name filter."},"custom_query":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Query","description":"Optional advanced filter JSON string (same format as the in-app custom query builder)."},"call_status":{"type":"string","enum":["all","live","completed"],"title":"Call Status","description":"Include \"all\" calls, only \"live\", or only \"completed\" (non-live).","default":"all"},"qai_only":{"type":"boolean","title":"Qai Only","description":"If true, only calls with a QAI transcript or QAI answers.","default":false},"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search","description":"Comma-separated terms matched against id, ANI, publisher number, and names."},"sort_field":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sort Field","description":"Sort column: id, effective_call_time, effective_call_time_utc, campaign_name, publisher_name, buyer_name, routing_plan_name, inbound_from, inbound_to, outbound_duration, inbound_duration, revenue_paid_out, publisher_paid_out, call_termination_by, dial_name, ring_time, is_moja_magic, cost, cost_per_min, billable_minutes. (effective_call_time and effective_call_time_utc both sort by the same underlying timestamp.)"},"sort_direction":{"type":"string","enum":["asc","desc"],"title":"Sort Direction","description":"Sort direction.","default":"desc"},"limit":{"type":"integer","maximum":200.0,"minimum":1.0,"title":"Limit","description":"Page size.","default":25},"offset":{"type":"integer","minimum":0.0,"title":"Offset","description":"Zero-based row offset.","default":0},"include_tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Include Tags","description":"Optional list of system and/or custom tag keys to attach on each call row under `tags`. Matching is case-insensitive (e.g. ORIGINAL_ZIP_CODE and original_zip_code are the same). Keys in the response use the normalized lowercase form. At most 50 unique tags. When omitted or empty, `tags` is not included.","examples":[["original_state","original_zip_code","voice_agent_test"]]}},"additionalProperties":false,"type":"object","required":["start_date","end_date"],"title":"ReportingCallsQueryRequest","description":"Query call-level transaction rows for the organization (full org access via API key)."},"ReportingCallsQueryResponse":{"properties":{"data":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Data","description":"Call log rows aligned with the in-app admin call log table: status, ids, campaign/publisher/buyer names and ids, routing plan, IVR fields, digits, inbound numbers, durations, ring time, dial target (dial_name, dialed_target, dial_type_id, and dial_type — the route action that selected the destination, e.g. route-to-target, route-to-rtb, route-to-rtb-group, route-to-sip-target, route-to-ivr — use this to distinguish a target from an RTB attribution), payouts and adjustment flags, termination fields, zip code, caller city and state (derived from zip code when a match exists), sticky_caller (true when sticky caller routing applied; backed by the STICKY_CALLER_ROUTED system tag), is_moja_magic, cost (computed per-row USD carrier cost: billable rate in cents/minute times ceil(inbound_duration/60) billable minutes divided by 100; zero for Moja Magic calls except for legacy org ids), cost_per_min (USD per billable minute), billable_minutes (per-call rounded minutes used for cost; zero for Moja Magic calls except for legacy org ids), the dedicated `rtb_id` / `rtb_name` and `target_id` / `target_name` fields (derived from dial_type/dial_type_id/dial_name: `rtb_*` is populated when dial_type is one of route-to-rtb, rtb_target, route-to-rtb-group, rtb, or rtb_group, and `target_*` is populated when dial_type is route-to-target or target), and a presigned recording_url when storage is configured. Omits UI-only columns and default QAI-only columns (disposition, category, sentiment). Each row includes two representations of the call timestamp: `effective_call_time` is the legacy naive UTC value formatted as `YYYY-MM-DD HH:MM:SS`, and `effective_call_time_utc` is the same instant in RFC 3339 UTC (`YYYY-MM-DDTHH:MM:SSZ`). Both fields always represent UTC; the request `timezone` only affects date filtering and grouping, not the response timestamp value. When the request includes `include_tags`, each row also has a `tags` object mapping each requested tag key to either null (not set on that call) or `{value, type}` where type is `system` or `custom`."},"meta":{"$ref":"#/components/schemas/PaginatedResponseMeta"},"completed_count":{"type":"integer","title":"Completed Count","description":"Count of completed (non-live) calls in the filtered set."},"live_count":{"type":"integer","title":"Live Count","description":"Count of live calls in the filtered set."}},"additionalProperties":false,"type":"object","required":["data","meta","completed_count","live_count"],"title":"ReportingCallsQueryResponse","description":"Paginated call rows plus aggregate call-status counts for the filtered set."},"ReportingCallsSummaryRequest":{"properties":{"group_by":{"type":"string","enum":["route-to-target","campaign","publisher","buyer","routing_plan","caller_id","target_number","publisher_number","ivr_menu","date"],"title":"Group By","description":"Summary dimension: route-to-target, campaign, publisher, buyer, routing_plan, caller_id, target_number, publisher_number, ivr_menu, or date.","default":"campaign"},"start_date":{"type":"string","title":"Start Date","description":"Inclusive range start (ISO 8601)."},"end_date":{"type":"string","title":"End Date","description":"Inclusive range end (ISO 8601)."},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone","description":"Required for group_by=date when grouping by local calendar day."},"campaign_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Campaign Id","description":"Restrict to this campaign id."},"publisher_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Publisher Id","description":"Restrict to this publisher id."},"buyer_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Id","description":"Restrict to this buyer id."},"routing_plan_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Routing Plan Id","description":"Restrict to this routing plan id."},"dial_type_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dial Type Id","description":"Restrict to dial_type_id / target."},"dialed_target":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dialed Target","description":"Restrict to dialed destination number."},"inbound_from":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inbound From","description":"Caller ID filter."},"inbound_to":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inbound To","description":"Publisher number filter."},"disposition":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Disposition","description":"QAI disposition name filter."},"custom_query":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Query","description":"Optional advanced filter JSON string."},"qai_only":{"type":"boolean","title":"Qai Only","description":"If true, only calls with QAI transcript or answers.","default":false},"search":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search","description":"Search string applied in underlying summary query if supported."},"qai_visible_columns":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Qai Visible Columns","description":"When qai_only is true, optional QAI columns to include in grouping (disposition, category, sentiment, hangup, termination_reason)."}},"additionalProperties":false,"type":"object","required":["start_date","end_date"],"title":"ReportingCallsSummaryRequest","description":"Aggregated metrics grouped by a single dimension (same options as the in-app summary report)."},"ReportingCallsSummaryResponse":{"properties":{"data":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Data","description":"Summary rows with metrics: calls, unique_calls, revenue, payout, profit, billable_minutes (admin: sum of per-call ceil(inbound_duration/60) with Moja Magic minutes excluded except for legacy org ids), cost (admin: sums per-call carrier cost with Moja Magic minutes excluded except for legacy org ids), conversion fields, etc., depending on group_by (same semantics as the in-app reporting summary)."}},"additionalProperties":false,"type":"object","required":["data"],"title":"ReportingCallsSummaryResponse"},"ResourceRef":{"properties":{"id":{"type":"string","title":"Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"}},"additionalProperties":false,"type":"object","required":["id"],"title":"ResourceRef"},"RoutingPlanCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"is_active":{"type":"boolean","title":"Is Active","default":false},"allowed_publishers":{"items":{"type":"string"},"type":"array","title":"Allowed Publishers"},"allowed_buyers":{"items":{"type":"string"},"type":"array","title":"Allowed Buyers"},"routes":{"items":{"$ref":"#/components/schemas/RoutingPlanRoute"},"type":"array","title":"Routes"},"predictive_routing_plan_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Predictive Routing Plan Id"},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id","description":"External system ID for migration purposes"}},"additionalProperties":false,"type":"object","required":["name"],"title":"RoutingPlanCreate"},"RoutingPlanListResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/RoutingPlanResponse"},"type":"array","title":"Data"},"meta":{"$ref":"#/components/schemas/PaginatedResponseMeta"}},"additionalProperties":false,"type":"object","required":["data","meta"],"title":"RoutingPlanListResponse"},"RoutingPlanPatch":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"allowed_publishers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Allowed Publishers"},"allowed_buyers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Allowed Buyers"},"routes":{"anyOf":[{"items":{"$ref":"#/components/schemas/RoutingPlanRoute"},"type":"array"},{"type":"null"}],"title":"Routes"},"predictive_routing_plan_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Predictive Routing Plan Id"},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id","description":"External system ID for migration purposes"}},"additionalProperties":false,"type":"object","title":"RoutingPlanPatch"},"RoutingPlanResponse":{"properties":{"id":{"type":"string","title":"Id"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"org_id":{"type":"string","title":"Org Id"},"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"is_active":{"type":"boolean","title":"Is Active"},"allowed_publishers":{"items":{"type":"string"},"type":"array","title":"Allowed Publishers"},"allowed_buyers":{"items":{"type":"string"},"type":"array","title":"Allowed Buyers"},"prefix":{"type":"string","title":"Prefix","default":""},"predictive_routing_plan_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Predictive Routing Plan Id"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id"},"routes":{"items":{"$ref":"#/components/schemas/RoutingPlanRouteResponse"},"type":"array","title":"Routes"}},"additionalProperties":false,"type":"object","required":["id","org_id","name","is_active"],"title":"RoutingPlanResponse"},"RoutingPlanRoute":{"properties":{"id":{"anyOf":[{"type":"string","maxLength":36,"minLength":1},{"type":"null"}],"title":"Id"},"action":{"type":"string","enum":["route-to-target","route-to-sip-target","route-to-ivr","route-to-rtb","route-to-rtb-group"],"title":"Action"},"target_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Id"},"rtb_formula_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rtb Formula Id"},"ivr_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ivr Id"},"rtb_group_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rtb Group Id"},"predictive_routing_plan_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Predictive Routing Plan Id"},"priority":{"type":"integer","minimum":0.0,"title":"Priority","default":0},"weight":{"type":"integer","minimum":0.0,"title":"Weight","default":0}},"additionalProperties":false,"type":"object","required":["action"],"title":"RoutingPlanRoute","description":"Stable route id (DB uuid). Omitted on create for new steps; returned as id on read."},"RoutingPlanRouteResponse":{"properties":{"id":{"anyOf":[{"type":"string","maxLength":36,"minLength":1},{"type":"null"}],"title":"Id"},"action":{"type":"string","enum":["route-to-target","route-to-sip-target","route-to-ivr","route-to-rtb","route-to-rtb-group"],"title":"Action"},"target_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Id"},"rtb_formula_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rtb Formula Id"},"ivr_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ivr Id"},"rtb_group_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rtb Group Id"},"predictive_routing_plan_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Predictive Routing Plan Id"},"priority":{"type":"integer","minimum":0.0,"title":"Priority","default":0},"weight":{"type":"integer","minimum":0.0,"title":"Weight","default":0},"target":{"anyOf":[{"$ref":"#/components/schemas/ResourceRef"},{"type":"null"}]},"rtb_formula":{"anyOf":[{"$ref":"#/components/schemas/ResourceRef"},{"type":"null"}]},"ivr":{"anyOf":[{"$ref":"#/components/schemas/ResourceRef"},{"type":"null"}]},"rtb_group":{"anyOf":[{"$ref":"#/components/schemas/ResourceRef"},{"type":"null"}]}},"additionalProperties":false,"type":"object","required":["action"],"title":"RoutingPlanRouteResponse"},"TargetCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"buyer_id":{"type":"string","minLength":1,"title":"Buyer Id"},"type":{"type":"string","enum":["number","phone","sip","sip_target","sip-target"],"title":"Type"},"number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Number"},"sip_endpoint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sip Endpoint"},"sip_username":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sip Username"},"sip_password":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sip Password"},"sip_headers":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Sip Headers","examples":[{"X-Campaign":"sales","X-Trace-Id":"trace-123"}]},"connection_timeout":{"anyOf":[{"type":"integer","maximum":120.0,"minimum":1.0},{"type":"null"}],"title":"Connection Timeout","description":"Static-target ring timeout in seconds. Must be a whole integer from 1 through 120. Null uses the platform default of 30 seconds for existing records."},"timezone":{"type":"string","title":"Timezone","default":"America/New_York","examples":["America/New_York"]},"is_active":{"type":"boolean","title":"Is Active","default":false},"max_concurrency":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Max Concurrency"},"revenue":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Revenue"},"payout":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Payout"},"payout_condition":{"type":"string","enum":["call_successfully_connected","call_length_connected"],"title":"Payout Condition","default":"call_successfully_connected"},"payout_condition_duration":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Payout Condition Duration"},"conversion_scope":{"type":"integer","minimum":0.0,"title":"Conversion Scope","default":10},"duplicate_conversion_action":{"type":"string","enum":["decline","route_no_pay","route_no_revenue","route_no_revenue_no_pay"],"title":"Duplicate Conversion Action","default":"decline"},"consider_duplicate":{"type":"boolean","title":"Consider Duplicate","default":false},"consider_duplicate_on":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Consider Duplicate On"},"consider_duplicate_length":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Consider Duplicate Length"},"consider_duplicate_interval":{"type":"integer","minimum":1.0,"title":"Consider Duplicate Interval","description":"Lookback window in days for the consider-duplicate check","default":30},"disable_recordings":{"type":"boolean","title":"Disable Recordings","default":false},"access_to_call_recordings":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Access To Call Recordings"},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","examples":[{"enabled":true,"groups":[{"conditions":[{"field":"state","operator":"in","values":["CA","TX"]}]}]}]},"hours_of_operation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Hours Of Operation","examples":[{"always_open":false,"days":[{"day":"monday","hours":"custom","isOpen":true,"timeRanges":[{"end":"17:00","start":"09:00"}]}]}]},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id","description":"External system ID for migration purposes"},"advanced_caps":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Advanced Caps"}},"additionalProperties":false,"type":"object","required":["name","buyer_id","type"],"title":"TargetCreate"},"TargetListResponse":{"properties":{"data":{"items":{"$ref":"#/components/schemas/TargetResponse"},"type":"array","title":"Data"},"meta":{"$ref":"#/components/schemas/PaginatedResponseMeta"}},"additionalProperties":false,"type":"object","required":["data","meta"],"title":"TargetListResponse"},"TargetPatch":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Name"},"buyer_id":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}],"title":"Buyer Id"},"type":{"anyOf":[{"type":"string","enum":["number","phone","sip","sip_target","sip-target"]},{"type":"null"}],"title":"Type"},"number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Number"},"sip_endpoint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sip Endpoint"},"sip_username":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sip Username"},"sip_password":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sip Password"},"sip_headers":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Sip Headers","examples":[{"X-Campaign":"sales","X-Trace-Id":"trace-123"}]},"connection_timeout":{"anyOf":[{"type":"integer","maximum":120.0,"minimum":1.0},{"type":"null"}],"title":"Connection Timeout","description":"Static-target ring timeout in seconds. Must be a whole integer from 1 through 120. Null uses the platform default of 30 seconds for existing records."},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone","examples":["America/New_York"]},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"max_concurrency":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Max Concurrency"},"revenue":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Revenue"},"payout":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Payout"},"payout_condition":{"type":"string","enum":["call_successfully_connected","call_length_connected"],"title":"Payout Condition","default":"call_successfully_connected"},"payout_condition_duration":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Payout Condition Duration"},"conversion_scope":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Conversion Scope"},"duplicate_conversion_action":{"anyOf":[{"type":"string","enum":["decline","route_no_pay","route_no_revenue","route_no_revenue_no_pay"]},{"type":"null"}],"title":"Duplicate Conversion Action"},"consider_duplicate":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Consider Duplicate"},"consider_duplicate_on":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Consider Duplicate On"},"consider_duplicate_length":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Consider Duplicate Length"},"consider_duplicate_interval":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Consider Duplicate Interval","description":"Lookback window in days for the consider-duplicate check"},"disable_recordings":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Disable Recordings"},"access_to_call_recordings":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Access To Call Recordings"},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","examples":[{"enabled":true,"groups":[{"conditions":[{"field":"state","operator":"in","values":["CA","TX"]}]}]}]},"hours_of_operation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Hours Of Operation","examples":[{"always_open":false,"days":[{"day":"monday","hours":"custom","isOpen":true,"timeRanges":[{"end":"17:00","start":"09:00"}]}]}]},"external_id":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"External Id","description":"External system ID for migration purposes"},"advanced_caps":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Advanced Caps"}},"additionalProperties":false,"type":"object","title":"TargetPatch"},"TargetResponse":{"properties":{"id":{"type":"string","title":"Id"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"name":{"type":"string","title":"Name"},"org_id":{"type":"string","title":"Org Id"},"buyer_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Id"},"buyer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Name"},"type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Type"},"number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Number"},"sip_endpoint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sip Endpoint"},"sip_username":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sip Username"},"sip_password":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sip Password"},"sip_headers":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Sip Headers","examples":[{"X-Campaign":"sales","X-Trace-Id":"trace-123"}]},"connection_timeout":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Connection Timeout","description":"Static-target ring timeout in seconds. Must be a whole integer from 1 through 120. Null uses the platform default of 30 seconds for existing records."},"timezone":{"type":"string","title":"Timezone","default":"America/New_York","examples":["America/New_York"]},"is_active":{"type":"boolean","title":"Is Active"},"max_concurrency":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Concurrency"},"revenue":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Revenue"},"payout":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Payout"},"payout_condition":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payout Condition"},"payout_condition_duration":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Payout Condition Duration"},"conversion_scope":{"type":"integer","title":"Conversion Scope"},"duplicate_conversion_action":{"type":"string","enum":["decline","route_no_pay","route_no_revenue","route_no_revenue_no_pay"],"title":"Duplicate Conversion Action","default":"decline"},"consider_duplicate":{"type":"boolean","title":"Consider Duplicate","default":false},"consider_duplicate_on":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Consider Duplicate On"},"consider_duplicate_length":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Consider Duplicate Length"},"consider_duplicate_interval":{"type":"integer","title":"Consider Duplicate Interval","default":30},"disable_recordings":{"type":"boolean","title":"Disable Recordings","default":false},"access_to_call_recordings":{"type":"boolean","title":"Access To Call Recordings"},"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","examples":[{"enabled":true,"groups":[{"conditions":[{"field":"state","operator":"in","values":["CA","TX"]}]}]}]},"hours_of_operation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Hours Of Operation","examples":[{"always_open":false,"days":[{"day":"monday","hours":"custom","isOpen":true,"timeRanges":[{"end":"17:00","start":"09:00"}]}]}]},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id"},"advanced_caps":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Advanced Caps"},"paused_until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Paused Until"},"paused_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Paused At"},"paused_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Paused By"},"is_paused":{"type":"boolean","title":"Is Paused","default":false}},"additionalProperties":false,"type":"object","required":["id","name","org_id","is_active","conversion_scope","access_to_call_recordings"],"title":"TargetResponse"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}},"securitySchemes":{"MojaApiKeyHeader":{"type":"apiKey","in":"header","name":"X-API-Key","description":"Organization API key."},"MojaApiBearer":{"type":"http","scheme":"bearer","bearerFormat":"API key","description":"Use the API key as a bearer token."}}},"tags":[{"name":"Campaigns","description":"Campaign operations using normalized tables."},{"name":"Targets","description":"Target operations."},{"name":"RTBs","description":"RTB formula operations."},{"name":"Routing Plans","description":"Routing plan operations using normalized routes."},{"name":"Buyers","description":"Buyer record operations."},{"name":"Publishers","description":"Publisher record operations."},{"name":"Reporting","description":"Read-only transaction reporting: call log rows and aggregated summaries."},{"name":"Inbound RTB analytics","description":"Inbound RTB request summaries, lists, allocations, and aggregate stats."},{"name":"Outbound RTB analytics","description":"Outbound RTB requests, per-request HTTP steps, and aggregate stats."},{"name":"Webhooks","description":"Incoming and outgoing webhook delivery history for your organization."},{"name":"Number pools","description":"Number-pool provisioning and allocation controls served by the integrations service."}],"servers":[{"url":"https://external-api.moja-ai.com"}]}