{
	"info": {
		"_postman_id": "veilstrat-pro-api-v1",
		"name": "VeilStrat Pro API v1",
		"description": "Scalpel REST for VeilStrat Pro. Set collection variables baseUrl and apiKey. Firehose is outbound — see Webhooks folder (docs only) and Settings → Webhooks.",
		"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json"
	},
	"variable": [
		{
			"key": "baseUrl",
			"value": "http://localhost:3000/api/v1"
		},
		{
			"key": "apiKey",
			"value": "vs_your_key_here"
		},
		{
			"key": "companyId",
			"value": ""
		},
		{
			"key": "sliceId",
			"value": "ai-sdr-hiring"
		}
	],
	"event": [
		{
			"listen": "prerequest",
			"script": {
				"type": "text/javascript",
				"exec": [
					"const key = pm.collectionVariables.get('apiKey');",
					"if (key) {",
					"  pm.request.headers.upsert({ key: 'Authorization', value: 'Bearer ' + key });",
					"}"
				]
			}
		}
	],
	"item": [
		{
			"name": "Health",
			"item": [
				{
					"name": "GET health",
					"request": {
						"method": "GET",
						"header": [
							{
								"key": "Accept",
								"value": "application/json"
							}
						],
						"url": "{{baseUrl}}/health",
						"description": "Uptime. Exempt from request budget."
					}
				}
			]
		},
		{
			"name": "Stats",
			"item": [
				{
					"name": "GET stats",
					"request": {
						"method": "GET",
						"header": [
							{
								"key": "Accept",
								"value": "application/json"
							}
						],
						"url": "{{baseUrl}}/stats",
						"description": "Usage + rate limits. Exempt from request budget."
					}
				}
			]
		},
		{
			"name": "Filters",
			"item": [
				{
					"name": "GET filters",
					"request": {
						"method": "GET",
						"header": [
							{
								"key": "Accept",
								"value": "application/json"
							}
						],
						"url": "{{baseUrl}}/filters",
						"description": "Enums and match rules for company search and slice search."
					}
				}
			]
		},
		{
			"name": "Companies",
			"item": [
				{
					"name": "POST company search",
					"event": [
						{
							"listen": "test",
							"script": {
								"type": "text/javascript",
								"exec": [
									"try {",
									"  const json = pm.response.json();",
									"  const id = json?.companies?.[0]?.id;",
									"  if (id) { pm.collectionVariables.set('companyId', id); }",
									"} catch (e) {}"
								]
							}
						}
					],
					"request": {
						"method": "POST",
						"header": [
							{
								"key": "Accept",
								"value": "application/json"
							},
							{
								"key": "Content-Type",
								"value": "application/json"
							}
						],
						"body": {
							"mode": "raw",
							"raw": "{\n  \"signal_query\": \"signal:hiring:30d\",\n  \"countries\": [\"US\"],\n  \"page\": 1,\n  \"pageSize\": 50\n}"
						},
						"url": "{{baseUrl}}/companies",
						"description": "Company search. signal_query required. Saves first company id to companyId."
					}
				},
				{
					"name": "GET company dossier",
					"request": {
						"method": "GET",
						"header": [
							{
								"key": "Accept",
								"value": "application/json"
							}
						],
						"url": "{{baseUrl}}/companies/{{companyId}}",
						"description": "Signal dossier for a company UUID."
					}
				}
			]
		},
		{
			"name": "Slices",
			"item": [
				{
					"name": "GET slice search",
					"request": {
						"method": "GET",
						"header": [
							{
								"key": "Accept",
								"value": "application/json"
							}
						],
						"url": {
							"raw": "{{baseUrl}}/slices?slice={{sliceId}}&countries=US&scoreMin=70",
							"host": [
								"{{baseUrl}}"
							],
							"path": [
								"slices"
							],
							"query": [
								{
									"key": "slice",
									"value": "{{sliceId}}"
								},
								{
									"key": "countries",
									"value": "US"
								},
								{
									"key": "scoreMin",
									"value": "70"
								}
							]
						},
						"description": "Slice search. Requires slice + at least one filter."
					}
				}
			]
		},
		{
			"name": "Webhooks",
			"item": [
				{
					"name": "Outbound only (read me)",
					"request": {
						"method": "GET",
						"header": [],
						"url": "{{baseUrl}}/health",
						"description": "Firehose is OUTBOUND — VeilStrat POSTs to your URL. Configure in Settings → Webhooks. Use scripts/firehose-webhook-receiver.mjs locally. This request is a placeholder so the folder imports; it is not a webhook API."
					}
				}
			]
		}
	]
}