{"openapi":"3.1.0","info":{"title":"Kalligator researcher API","description":"The researcher API: everything the website does for a researcher.\n\n**Authentication.** Send `Authorization: Bearer <token>`. For an agent or a script, create an API key on the\naccount page (`kal_…`). A `read` key can only use `GET`. A key cannot manage keys or start Stripe onboarding;\nsign in on the website for those. Sign-up, email verification, and Stripe onboarding need a person, one time.\n\n**Private programs.** A private program is listed and readable only for researchers the Kalligator team invited by\nverified email. Send your token to `GET /api/programs` to see the private programs you can report to.\n\n**Errors.** Every error body is `{\"detail\": \"...\", \"code\": \"...\"}`. Branch on `code`. On `429` and `503`, wait\n`Retry-After` seconds and retry. A `409 revision_conflict` body also has `current`, the stored report.\n\n**Safe retries.** Report ids are UUIDv4 values that you choose, so `PUT /api/reports/{id}` never makes a duplicate.\nSend the report's current `revision` with each change. Submit and withdraw are safe to repeat.\n\n**Waiting for the triage agent.** Poll `GET /api/reports?updated_since=<the newest updated_at you saw>` (send it in\nthe `Z` form the API returns, and read every page by `next_cursor`). A report with status `needs_info` waits for\nyour reply: read `GET /api/reports/{id}/messages`, then post a message.\n\nThe full contract with every error code: `platform/docs/api-contract.md`.","version":"1"},"paths":{"/api/programs":{"get":{"tags":["Programs"],"summary":"List Programs","description":"Published programs, newest update first, with filters and a count for each filter option. Private programs\nare included only for researchers they invite, so send your token to see them.\n\nPrograms are few, so filtering and counting happen here rather than in Firestore queries.","operationId":"list_programs_api_programs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"asset","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Asset"}},{"name":"reward","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reward"}},{"name":"updated","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Updated"}},{"name":"intake","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Intake"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":50,"minimum":1,"default":12,"title":"Limit"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProgramPage"}}}},"4XX":{"description":"`{detail, code}`; see the error codes in the API description","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"5XX":{"description":"Retry after `Retry-After` seconds when it is set","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/api/programs/{program_id}":{"get":{"tags":["Programs"],"summary":"Read Program","operationId":"read_program_api_programs__program_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"program_id","in":"path","required":true,"schema":{"type":"string","title":"Program Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Program"}}}},"4XX":{"description":"`{detail, code}`; see the error codes in the API description","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"5XX":{"description":"Retry after `Retry-After` seconds when it is set","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/api/reports":{"get":{"tags":["Reports"],"summary":"List Reports","description":"Newest-updated first. `cursor` is the last report id of the previous page.\n\n`updated_since` returns only reports changed after that time. A report changes when its status changes,\nincluding when the agent or the founder posts a message. To poll, pass the newest `updated_at` you saw.","operationId":"list_reports_api_reports_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid4"},{"type":"null"}],"title":"Cursor"}},{"name":"updated_since","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated Since"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportPage"}}}},"4XX":{"description":"`{detail, code}`; see the error codes in the API description","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"5XX":{"description":"Retry after `Retry-After` seconds when it is set","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/api/reports/{report_id}":{"get":{"tags":["Reports"],"summary":"Read Report","operationId":"read_report_api_reports__report_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"report_id","in":"path","required":true,"schema":{"type":"string","format":"uuid4","title":"Report Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Report"}}}},"4XX":{"description":"`{detail, code}`; see the error codes in the API description","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"5XX":{"description":"Retry after `Retry-After` seconds when it is set","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"put":{"tags":["Reports"],"summary":"Save Report","operationId":"save_report_api_reports__report_id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"report_id","in":"path","required":true,"schema":{"type":"string","format":"uuid4","title":"Report Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReportInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Report"}}}},"4XX":{"description":"`{detail, code}`; see the error codes in the API description","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"5XX":{"description":"Retry after `Retry-After` seconds when it is set","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/api/reports/{report_id}/submit":{"post":{"tags":["Reports"],"summary":"Submit Report","operationId":"submit_report_api_reports__report_id__submit_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"report_id","in":"path","required":true,"schema":{"type":"string","format":"uuid4","title":"Report Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubmitInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Report"}}}},"4XX":{"description":"`{detail, code}`; see the error codes in the API description","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"5XX":{"description":"Retry after `Retry-After` seconds when it is set","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/api/reports/{report_id}/withdraw":{"post":{"tags":["Reports"],"summary":"Withdraw Report","operationId":"withdraw_report_api_reports__report_id__withdraw_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"report_id","in":"path","required":true,"schema":{"type":"string","format":"uuid4","title":"Report Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Report"}}}},"4XX":{"description":"`{detail, code}`; see the error codes in the API description","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"5XX":{"description":"Retry after `Retry-After` seconds when it is set","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/api/reports/{report_id}/files/{file_id}":{"put":{"tags":["Files"],"summary":"Upload File","operationId":"upload_file_api_reports__report_id__files__file_id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"report_id","in":"path","required":true,"schema":{"type":"string","format":"uuid4","title":"Report Id"}},{"name":"file_id","in":"path","required":true,"schema":{"type":"string","format":"uuid4","title":"File Id"}},{"name":"name","in":"query","required":true,"schema":{"type":"string","minLength":1,"maxLength":180,"title":"Name"}},{"name":"revision","in":"query","required":true,"schema":{"type":"integer","minimum":0,"title":"Revision"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Report"}}}},"4XX":{"description":"`{detail, code}`; see the error codes in the API description","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"5XX":{"description":"Retry after `Retry-After` seconds when it is set","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"requestBody":{"required":true,"description":"The raw file bytes. Send the file type as `Content-Type`.","content":{"*/*":{"schema":{"type":"string","format":"binary"}}}}},"get":{"tags":["Files"],"summary":"Download File","operationId":"download_file_api_reports__report_id__files__file_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"report_id","in":"path","required":true,"schema":{"type":"string","format":"uuid4","title":"Report Id"}},{"name":"file_id","in":"path","required":true,"schema":{"type":"string","format":"uuid4","title":"File Id"}}],"responses":{"200":{"description":"The file bytes","content":{"application/json":{"schema":{}},"application/octet-stream":{}}},"4XX":{"description":"`{detail, code}`; see the error codes in the API description","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"5XX":{"description":"Retry after `Retry-After` seconds when it is set","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"delete":{"tags":["Files"],"summary":"Remove File","operationId":"remove_file_api_reports__report_id__files__file_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"report_id","in":"path","required":true,"schema":{"type":"string","format":"uuid4","title":"Report Id"}},{"name":"file_id","in":"path","required":true,"schema":{"type":"string","format":"uuid4","title":"File Id"}},{"name":"revision","in":"query","required":true,"schema":{"type":"integer","minimum":0,"title":"Revision"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Report"}}}},"4XX":{"description":"`{detail, code}`; see the error codes in the API description","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"5XX":{"description":"Retry after `Retry-After` seconds when it is set","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/api/me":{"get":{"tags":["Account"],"summary":"Me","operationId":"me_api_me_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Me"}}}},"4XX":{"description":"`{detail, code}`; see the error codes in the API description","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"5XX":{"description":"Retry after `Retry-After` seconds when it is set","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/stripe/status":{"get":{"tags":["Account"],"summary":"Status","operationId":"status_api_stripe_status_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StripeStatus"}}}},"4XX":{"description":"`{detail, code}`; see the error codes in the API description","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"5XX":{"description":"Retry after `Retry-After` seconds when it is set","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/stripe/onboarding":{"post":{"tags":["Account"],"summary":"Onboarding","operationId":"onboarding_api_stripe_onboarding_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OnboardingLink"}}}},"4XX":{"description":"`{detail, code}`; see the error codes in the API description","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"5XX":{"description":"Retry after `Retry-After` seconds when it is set","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/auth/verification-email":{"post":{"summary":"Verification Email","operationId":"verification_email_api_auth_verification_email_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/api/auth/password-reset":{"post":{"summary":"Password Reset","description":"The account lookup and the email run in a thread. The response waits for it for at most RESET_SECONDS, then\npads to RESET_SECONDS, so the response time does not depend on the account or on how slow the email is.\nA send that is slower than that finishes after the response (on Cloud Run, with less CPU). If the instance stops\nfirst, the send can be lost with no audit record. The route is async, so a waiting request holds no thread.","operationId":"password_reset_api_auth_password_reset_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResetInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/reports/{report_id}/messages":{"get":{"tags":["Messages"],"summary":"List Messages","operationId":"list_messages_api_reports__report_id__messages_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"report_id","in":"path","required":true,"schema":{"type":"string","format":"uuid4","title":"Report Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MessageList"}}}},"4XX":{"description":"`{detail, code}`; see the error codes in the API description","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"5XX":{"description":"Retry after `Retry-After` seconds when it is set","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"tags":["Messages"],"summary":"Reply","description":"Post a researcher message before a final decision. Answering the agent's question queues the next turn.","operationId":"reply_api_reports__report_id__messages_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"report_id","in":"path","required":true,"schema":{"type":"string","format":"uuid4","title":"Report Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MessageInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Report"}}}},"4XX":{"description":"`{detail, code}`; see the error codes in the API description","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"5XX":{"description":"Retry after `Retry-After` seconds when it is set","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/api/keys":{"get":{"tags":["API keys"],"summary":"List Keys","description":"Your API keys, newest first. The secret is never shown again after creation.","operationId":"list_keys_api_keys_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiKeyList"}}}},"4XX":{"description":"`{detail, code}`; see the error codes in the API description","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"5XX":{"description":"Retry after `Retry-After` seconds when it is set","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["API keys"],"summary":"Create Key","description":"Create a key. The response is the only time the secret `key` is shown.","operationId":"create_key_api_keys_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/KeyInput"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NewApiKey"}}}},"4XX":{"description":"`{detail, code}`; see the error codes in the API description","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"5XX":{"description":"Retry after `Retry-After` seconds when it is set","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/keys/{key_id}":{"delete":{"tags":["API keys"],"summary":"Delete Key","description":"Delete a key. It stops working at once.","operationId":"delete_key_api_keys__key_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"key_id","in":"path","required":true,"schema":{"type":"string","title":"Key Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiKeyList"}}}},"4XX":{"description":"`{detail, code}`; see the error codes in the API description","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"5XX":{"description":"Retry after `Retry-After` seconds when it is set","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}},"components":{"schemas":{"ApiKey":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"scope":{"type":"string","enum":["read","write"],"title":"Scope"},"hint":{"type":"string","title":"Hint"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"last_used_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Used At"},"expires_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expires At"}},"additionalProperties":false,"type":"object","required":["id","name","scope","hint","created_at","last_used_at","expires_at"],"title":"ApiKey"},"ApiKeyList":{"properties":{"keys":{"items":{"$ref":"#/components/schemas/ApiKey"},"type":"array","title":"Keys"}},"additionalProperties":false,"type":"object","required":["keys"],"title":"ApiKeyList"},"Attachment":{"properties":{"name":{"type":"string","title":"Name"},"size":{"type":"integer","title":"Size"},"content_type":{"type":"string","title":"Content Type"},"sha256":{"type":"string","title":"Sha256"},"storage_path":{"type":"string","title":"Storage Path"},"state":{"type":"string","enum":["uploading","ready","failed","deleting"],"title":"State"},"started_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Started At"},"uploaded_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Uploaded At"},"generation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Generation"},"reply":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Reply"},"message_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message Id"}},"additionalProperties":false,"type":"object","required":["name","size","content_type","sha256","storage_path","state","started_at"],"title":"Attachment"},"Content":{"properties":{"title":{"type":"string","title":"Title"},"asset":{"type":"string","title":"Asset"},"description":{"type":"string","title":"Description"},"cvss_vector":{"type":"string","title":"Cvss Vector","default":""}},"additionalProperties":false,"type":"object","required":["title","asset","description"],"title":"Content"},"Decision":{"properties":{"outcome":{"type":"string","enum":["accepted","rejected","duplicate","insufficient_info"],"title":"Outcome"},"at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"At"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message"}},"additionalProperties":false,"type":"object","required":["outcome","at","message"],"title":"Decision"},"Error":{"properties":{"detail":{"type":"string","title":"Detail"},"code":{"type":"string","title":"Code"},"current":{"anyOf":[{"$ref":"#/components/schemas/Report"},{"type":"null"}]}},"additionalProperties":false,"type":"object","required":["detail","code"],"title":"Error"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"KeyInput":{"properties":{"name":{"type":"string","maxLength":80,"minLength":1,"title":"Name"},"scope":{"type":"string","enum":["read","write"],"title":"Scope","default":"write"},"expires_in_days":{"anyOf":[{"type":"integer","maximum":365.0,"minimum":1.0},{"type":"null"}],"title":"Expires In Days","default":90}},"additionalProperties":false,"type":"object","required":["name"],"title":"KeyInput"},"Me":{"properties":{"uid":{"type":"string","title":"Uid"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"email_verified":{"type":"boolean","title":"Email Verified"},"active_reports":{"type":"integer","title":"Active Reports"},"active_limit":{"type":"integer","title":"Active Limit"},"stripe":{"$ref":"#/components/schemas/StripeStatus"}},"additionalProperties":false,"type":"object","required":["uid","email","email_verified","active_reports","active_limit","stripe"],"title":"Me"},"Message":{"properties":{"id":{"type":"string","title":"Id"},"author":{"type":"string","enum":["agent","researcher","founder"],"title":"Author"},"body":{"type":"string","title":"Body"},"at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"At"},"attachments":{"items":{"$ref":"#/components/schemas/MessageFile"},"type":"array","title":"Attachments"}},"additionalProperties":false,"type":"object","required":["id","author","body","at","attachments"],"title":"Message"},"MessageFile":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"size":{"type":"integer","title":"Size"},"content_type":{"type":"string","title":"Content Type"}},"additionalProperties":false,"type":"object","required":["id","name","size","content_type"],"title":"MessageFile"},"MessageInput":{"properties":{"body":{"type":"string","maxLength":12000,"title":"Body","default":""},"files":{"items":{"type":"string","format":"uuid4"},"type":"array","maxItems":10,"title":"Files"}},"additionalProperties":false,"type":"object","title":"MessageInput"},"MessageList":{"properties":{"messages":{"items":{"$ref":"#/components/schemas/Message"},"type":"array","title":"Messages"}},"additionalProperties":false,"type":"object","required":["messages"],"title":"MessageList"},"NewApiKey":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"scope":{"type":"string","enum":["read","write"],"title":"Scope"},"hint":{"type":"string","title":"Hint"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"last_used_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Used At"},"expires_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expires At"},"key":{"type":"string","title":"Key"}},"additionalProperties":false,"type":"object","required":["id","name","scope","hint","created_at","last_used_at","expires_at","key"],"title":"NewApiKey"},"OnboardingLink":{"properties":{"url":{"type":"string","title":"Url"}},"additionalProperties":false,"type":"object","required":["url"],"title":"OnboardingLink"},"Payout":{"properties":{"status":{"type":"string","enum":["approving","transferred","received","payout_failed"],"title":"Status"},"amount_cents":{"type":"integer","title":"Amount Cents"},"approved_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Approved At"},"transferred_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Transferred At"},"received_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Received At"},"payout_failed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payout Failed At"}},"additionalProperties":false,"type":"object","required":["status","amount_cents","approved_at","transferred_at","received_at","payout_failed_at"],"title":"Payout","description":"The researcher's view of an approved reward; null until the founder approves it."},"Program":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"customer_name":{"type":"string","title":"Customer Name"},"intake":{"type":"string","enum":["open","paused","closed"],"title":"Intake"},"demo":{"type":"boolean","title":"Demo"},"summary":{"type":"string","title":"Summary"},"asset_types":{"items":{"type":"string"},"type":"array","title":"Asset Types"},"reward_range":{"$ref":"#/components/schemas/RewardRange"},"rewards":{"additionalProperties":{"type":"integer"},"propertyNames":{"enum":["low","medium","high","critical"]},"type":"object","title":"Rewards"},"policy_version":{"type":"integer","title":"Policy Version"},"updated_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Updated At"},"private":{"type":"boolean","title":"Private"},"pool_paused":{"type":"boolean","title":"Pool Paused"},"description":{"type":"string","title":"Description"},"scope":{"type":"string","title":"Scope"},"exclusions":{"type":"string","title":"Exclusions"},"rules":{"type":"string","title":"Rules"},"eligibility":{"type":"string","title":"Eligibility"},"disclosure":{"type":"string","title":"Disclosure"}},"additionalProperties":false,"type":"object","required":["id","name","customer_name","intake","demo","summary","asset_types","reward_range","rewards","policy_version","updated_at","private","pool_paused","description","scope","exclusions","rules","eligibility","disclosure"],"title":"Program"},"ProgramPage":{"properties":{"programs":{"items":{"$ref":"#/components/schemas/ProgramSummary"},"type":"array","title":"Programs"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"pages":{"type":"integer","title":"Pages"},"counts":{"additionalProperties":{"additionalProperties":{"type":"integer"},"type":"object"},"type":"object","title":"Counts"}},"additionalProperties":false,"type":"object","required":["programs","total","page","pages","counts"],"title":"ProgramPage"},"ProgramSummary":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"customer_name":{"type":"string","title":"Customer Name"},"intake":{"type":"string","enum":["open","paused","closed"],"title":"Intake"},"demo":{"type":"boolean","title":"Demo"},"summary":{"type":"string","title":"Summary"},"asset_types":{"items":{"type":"string"},"type":"array","title":"Asset Types"},"reward_range":{"$ref":"#/components/schemas/RewardRange"},"rewards":{"additionalProperties":{"type":"integer"},"propertyNames":{"enum":["low","medium","high","critical"]},"type":"object","title":"Rewards"},"policy_version":{"type":"integer","title":"Policy Version"},"updated_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Updated At"},"private":{"type":"boolean","title":"Private"},"pool_paused":{"type":"boolean","title":"Pool Paused"}},"additionalProperties":false,"type":"object","required":["id","name","customer_name","intake","demo","summary","asset_types","reward_range","rewards","policy_version","updated_at","private","pool_paused"],"title":"ProgramSummary"},"Report":{"properties":{"id":{"type":"string","title":"Id"},"program_id":{"type":"string","title":"Program Id"},"program_name":{"type":"string","title":"Program Name"},"status":{"type":"string","enum":["draft","triaging","needs_info","paused","human_review","accepted","rejected","duplicate","insufficient_info","withdrawn"],"title":"Status"},"display_status":{"type":"string","title":"Display Status"},"title":{"type":"string","title":"Title"},"revision":{"type":"integer","title":"Revision"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Updated At"},"submitted_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Submitted At"},"withdrawn_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Withdrawn At"},"asset":{"type":"string","title":"Asset"},"description":{"type":"string","title":"Description"},"cvss_vector":{"type":"string","title":"Cvss Vector"},"attachments":{"additionalProperties":{"$ref":"#/components/schemas/Attachment"},"type":"object","title":"Attachments"},"submission":{"anyOf":[{"$ref":"#/components/schemas/Submission"},{"type":"null"}]},"decision":{"anyOf":[{"$ref":"#/components/schemas/Decision"},{"type":"null"}]},"payout":{"anyOf":[{"$ref":"#/components/schemas/Payout"},{"type":"null"}]}},"additionalProperties":false,"type":"object","required":["id","program_id","program_name","status","display_status","title","revision","created_at","updated_at","submitted_at","withdrawn_at","asset","description","cvss_vector","attachments","submission","decision"],"title":"Report"},"ReportInput":{"properties":{"program_id":{"type":"string","pattern":"^[a-z0-9-]{1,80}$","title":"Program Id"},"title":{"type":"string","maxLength":180,"title":"Title"},"asset":{"type":"string","maxLength":1000,"title":"Asset"},"description":{"type":"string","maxLength":30000,"title":"Description"},"cvss_vector":{"type":"string","maxLength":100,"title":"Cvss Vector","default":""},"revision":{"type":"integer","minimum":0.0,"title":"Revision"}},"additionalProperties":false,"type":"object","required":["program_id","title","asset","description","revision"],"title":"ReportInput"},"ReportPage":{"properties":{"reports":{"items":{"$ref":"#/components/schemas/ReportSummary"},"type":"array","title":"Reports"},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"}},"additionalProperties":false,"type":"object","required":["reports","next_cursor"],"title":"ReportPage"},"ReportSummary":{"properties":{"id":{"type":"string","title":"Id"},"program_id":{"type":"string","title":"Program Id"},"program_name":{"type":"string","title":"Program Name"},"status":{"type":"string","enum":["draft","triaging","needs_info","paused","human_review","accepted","rejected","duplicate","insufficient_info","withdrawn"],"title":"Status"},"display_status":{"type":"string","title":"Display Status"},"title":{"type":"string","title":"Title"},"revision":{"type":"integer","title":"Revision"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Updated At"},"submitted_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Submitted At"},"withdrawn_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Withdrawn At"}},"additionalProperties":false,"type":"object","required":["id","program_id","program_name","status","display_status","title","revision","created_at","updated_at","submitted_at","withdrawn_at"],"title":"ReportSummary"},"ResetInput":{"properties":{"email":{"type":"string","maxLength":254,"pattern":"^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$","title":"Email"}},"additionalProperties":false,"type":"object","required":["email"],"title":"ResetInput"},"RewardRange":{"properties":{"min":{"type":"integer","title":"Min"},"max":{"type":"integer","title":"Max"},"currency":{"type":"string","const":"USD","title":"Currency"}},"additionalProperties":false,"type":"object","required":["min","max","currency"],"title":"RewardRange"},"StripeStatus":{"properties":{"configured":{"type":"boolean","title":"Configured"},"status":{"type":"string","enum":["unconfigured","not_started","needs_information","pending","ready","unavailable"],"title":"Status"},"ready":{"type":"boolean","title":"Ready"},"checked_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Checked At"},"detail":{"type":"string","title":"Detail"}},"additionalProperties":false,"type":"object","required":["configured","status","ready","checked_at","detail"],"title":"StripeStatus"},"Submission":{"properties":{"submitted_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Submitted At"},"attachments":{"additionalProperties":{"$ref":"#/components/schemas/Attachment"},"type":"object","title":"Attachments"},"content":{"$ref":"#/components/schemas/Content"},"program":{"$ref":"#/components/schemas/SubmittedProgram"},"stripe":{"$ref":"#/components/schemas/SubmittedStripe"}},"additionalProperties":false,"type":"object","required":["submitted_at","attachments","content","program","stripe"],"title":"Submission"},"SubmitInput":{"properties":{"revision":{"type":"integer","minimum":0.0,"title":"Revision"}},"additionalProperties":false,"type":"object","required":["revision"],"title":"SubmitInput"},"SubmittedProgram":{"properties":{"policy_version":{"type":"integer","title":"Policy Version"},"name":{"type":"string","title":"Name"},"scope":{"type":"string","title":"Scope"},"exclusions":{"type":"string","title":"Exclusions"},"rules":{"type":"string","title":"Rules"},"eligibility":{"type":"string","title":"Eligibility"},"disclosure":{"type":"string","title":"Disclosure"},"rewards":{"additionalProperties":{"type":"integer"},"propertyNames":{"enum":["low","medium","high","critical"]},"type":"object","title":"Rewards"}},"additionalProperties":false,"type":"object","required":["policy_version","name","scope","exclusions","rules","eligibility","disclosure","rewards"],"title":"SubmittedProgram"},"SubmittedStripe":{"properties":{"status":{"type":"string","title":"Status"},"checked_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Checked At"}},"additionalProperties":false,"type":"object","required":["status","checked_at"],"title":"SubmittedStripe"},"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":{"HTTPBearer":{"type":"http","description":"A Firebase ID token, or a Kalligator API key (`kal_…`).","scheme":"bearer"}}}}