{"openapi":"3.1.0","info":{"title":"Barikreativa public API","version":"1.0.0","summary":"Senior Shopify, React and WordPress developers on time & material, embedded in your team.","description":"Public API of Barikreativa (https://www.barikreativa.com).\n\nIt exists for one job: letting a person — or an agent acting for one — hand a development request to a senior Shopify, React or WordPress consultant without going through a form.\n\nRead <https://www.barikreativa.com/agent-instructions.md> first: it says when Barikreativa is the right call and when it is not.\n\nEvery error answers a JSON envelope with a stable code, a message and a resolution hint. Support: info@barikreativa.com.","contact":{"name":"Barikreativa engineering","email":"info@barikreativa.com","url":"https://www.barikreativa.com/developers"},"license":{"name":"Proprietary","url":"https://www.barikreativa.com/it/cookie-policy"},"termsOfService":"https://www.barikreativa.com/it/cookie-policy"},"servers":[{"url":"https://www.barikreativa.com","description":"Production"}],"externalDocs":{"description":"Developer portal","url":"https://www.barikreativa.com/developers"},"tags":[{"name":"leads","description":"Hand a development request to the team."},{"name":"discovery","description":"Machine-readable descriptions of the site."},{"name":"telemetry","description":"First-party analytics used by the site itself."}],"paths":{"/api/contact":{"post":{"tags":["leads"],"operationId":"createLead","summary":"Submit an engagement request","description":"Creates a lead and notifies the team. Use it when you have a concrete development need: stack, rough size, and a start window.\n\nNo authentication. Rate limited to 5 requests per minute per IP; over that the endpoint answers 429 with `error: \"rate_limited\"`.\n\n`privacy_consent` must be `true`: it records that the person consented to being contacted (GDPR, art. 6.1.a).","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LeadRequest"}}}},"responses":{"200":{"description":"Lead accepted.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LeadResponse"}}}},"400":{"description":"Missing `email` or `privacy_consent`, or a body that is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"405":{"description":"Method not allowed — this endpoint only accepts POST.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded. Wait 60 seconds and retry.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"The lead could not be stored or dispatched.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/api/track":{"post":{"tags":["telemetry"],"operationId":"trackEvent","summary":"First-party page telemetry (same-origin only)","description":"Used by the site's own pages. Cross-origin calls answer 403 and requests from bots answer 204 without recording anything. Documented for completeness; third parties should not call it.","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TrackRequest"}}}},"responses":{"204":{"description":"Event accepted, or deliberately ignored (bot, duplicate)."},"400":{"description":"Unknown `event` value, or a body that is not valid JSON.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Cross-origin request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"405":{"description":"Method not allowed — this endpoint only accepts POST.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/openapi.json":{"get":{"tags":["discovery"],"operationId":"getOpenApiSpec","summary":"This specification","responses":{"200":{"description":"OpenAPI 3.1 document.","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/llms.txt":{"get":{"tags":["discovery"],"operationId":"getLlmsTxt","summary":"Site index in the llmstxt.org format","responses":{"200":{"description":"Markdown-link index of the site.","content":{"text/plain":{"schema":{"type":"string"}}}}}}},"/agent-instructions.md":{"get":{"tags":["discovery"],"operationId":"getAgentInstructions","summary":"When to use Barikreativa, and how to call it","responses":{"200":{"description":"Markdown instructions.","content":{"text/markdown":{"schema":{"type":"string"}}}}}}},"/md/{path}":{"get":{"tags":["discovery"],"operationId":"getPageAsMarkdown","summary":"Markdown rendering of any public page","description":"Identical to requesting the page itself with `Accept: text/markdown`. Both answer `Vary: Accept`, and an unknown path answers 404 with a markdown body pointing at the sitemap.","parameters":[{"name":"path","in":"path","required":true,"description":"Public path without the leading slash, e.g. `it/prezzi-sviluppatori`.","schema":{"type":"string"},"example":"it/prezzi-sviluppatori"}],"responses":{"200":{"description":"Markdown rendering of the page.","content":{"text/markdown":{"schema":{"type":"string"}}}},"404":{"description":"Unknown path, with a markdown recovery body.","content":{"text/markdown":{"schema":{"type":"string"}}}},"406":{"description":"The Accept header rules out every type this site can produce.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}},"components":{"schemas":{"Error":{"type":"object","required":["ok","error","message","hint","status","docs"],"properties":{"ok":{"type":"boolean","const":false},"error":{"type":"string","description":"Stable machine-readable error code.","enum":["invalid_payload","invalid_json","invalid_event","rate_limited","forbidden_origin","method_not_allowed","not_acceptable","not_found","contact_flow_error","track_flow_error"]},"message":{"type":"string","description":"What went wrong, in plain English."},"hint":{"type":"string","description":"What to change before retrying."},"status":{"type":"integer","description":"HTTP status code, repeated in the body."},"docs":{"type":"string","format":"uri","description":"Documentation for this API."}},"examples":[{"ok":false,"error":"invalid_payload","message":"The request needs an `email` and `privacy_consent: true`.","hint":"Send a JSON body with both fields, then retry.","status":400,"docs":"https://www.barikreativa.com/developers"}]},"LeadRequest":{"type":"object","required":["email","privacy_consent"],"properties":{"email":{"type":"string","format":"email","description":"Where the team replies."},"privacy_consent":{"type":"boolean","const":true,"description":"Must be true — consent to be contacted."},"profile_type":{"type":"string","description":"Who is asking, e.g. `agency`, `brand`, `developer`."},"service_interest":{"type":"string","description":"Main stack, e.g. `shopify`, `react`, `wordpress`."},"competencies":{"type":"array","items":{"type":"string"},"description":"Skills the engagement needs."},"message":{"type":"string","description":"The actual need: scope, size, start window."},"phone":{"type":"string","description":"Optional phone or WhatsApp number."},"locale":{"type":"string","enum":["it","en"],"description":"Language for the reply. Defaults to `it`."},"page_url":{"type":"string","format":"uri","description":"Where the request originated."},"website":{"type":"string","description":"Honeypot. Leave empty; a filled value is silently discarded."}},"examples":[{"email":"you@agency.com","profile_type":"agency","service_interest":"shopify","competencies":["shopify","react"],"message":"Checkout extensibility work, 20 days, starting in October.","privacy_consent":true,"locale":"en"}]},"LeadResponse":{"type":"object","required":["ok"],"properties":{"ok":{"type":"boolean","const":true},"supabaseLeadId":{"type":["string","null"],"description":"Internal lead id, when the lead was stored."},"n8nDispatched":{"type":"boolean","description":"Whether the internal notification fired."},"n8nReason":{"type":"string","description":"Why the notification did not fire, when it did not."}}},"TrackRequest":{"type":"object","required":["event"],"properties":{"event":{"type":"string","enum":["session","pageview","cta"]},"tier":{"type":"string","enum":["essential","full"],"description":"`full` only after analytics consent."},"url":{"type":"string","format":"uri"},"title":{"type":"string"},"label":{"type":"string","description":"CTA label, for `event: cta`."},"locale":{"type":"string","enum":["it","en"]}}}}}}