{"openapi":"3.1.0","info":{"title":"Hermes Portugal PT-Data API (x402)","description":"Pay-per-call Portuguese data API using the x402 v2 protocol. Call a paid endpoint without payment to receive HTTP 402 and a base64-encoded PAYMENT-REQUIRED header. Sign the payment and retry with PAYMENT-SIGNATURE. Prices are denominated in USDC on Base mainnet.","version":"1.1.0"},"paths":{"/.well-known/agent.json":{"get":{"summary":"Synmerco Agent Json","operationId":"synmerco_agent_json__well_known_agent_json_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/.well-known/agent-card.json":{"get":{"summary":"Agent discovery card","operationId":"getAgentCard","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"tags":["Service"]}},"/health":{"get":{"summary":"API health and payment configuration","operationId":"getHealth","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"tags":["Service"]}},"/v1/realestate/latest":{"get":{"summary":"Daily Portuguese real-estate listings","operationId":"getRealEstateListings","parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","default":1,"title":"Page","minimum":1},"description":"1-based result page; each page contains at most 100 rows."},{"name":"PAYMENT-SIGNATURE","in":"header","required":false,"description":"Base64-encoded x402 v2 payment payload obtained after the initial HTTP 402 challenge.","schema":{"type":"string"}}],"responses":{"200":{"description":"Payment verified and settled; requested dataset page returned.","content":{"application/json":{"schema":{"type":"object","required":["source","total_rows","page","page_size","total_pages","rows"],"properties":{"source":{"type":"string"},"total_rows":{"type":"integer"},"page":{"type":"integer","minimum":1},"page_size":{"type":"integer","const":100},"total_pages":{"type":"integer","minimum":1},"rows":{"type":"array","maxItems":100,"items":{"type":"object","required":["listing_id","title","city","price_eur","url"],"properties":{"listing_id":{"type":"string"},"title":{"type":"string"},"property_type":{"type":"string"},"listing_type":{"type":"string"},"market":{"type":"string"},"city":{"type":"string"},"region":{"type":"string"},"lon":{"type":"string"},"lat":{"type":"string"},"bedrooms":{"type":"string"},"bathrooms":{"type":"string"},"listing_date":{"type":"string"},"agent_url":{"type":"string"},"price_eur":{"type":"string"},"url":{"type":"string"},"competence_date":{"type":"string"}}}}}}}},"headers":{"PAYMENT-RESPONSE":{"description":"Base64-encoded x402 settlement response.","schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}},"402":{"description":"Payment required or invalid. Decode PAYMENT-REQUIRED, sign the payment, and retry.","headers":{"PAYMENT-REQUIRED":{"description":"Base64-encoded x402 v2 payment requirements.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object"},"example":{}}}}},"description":"Returns up to 100 casa.sapo property listings per page. Requires x402 payment of $0.02 in USDC on Base mainnet.","tags":["Real Estate"],"x-x402":{"version":2,"scheme":"exact","network":"eip155:8453","price":"$0.02","asset":"USDC","paymentHeader":"PAYMENT-SIGNATURE"},"x-mercado-price-micros":20000,"x-mercado-max-price-micros":20000}},"/v1/procurement/tenders":{"get":{"summary":"Portuguese public procurement tenders","operationId":"getProcurementTenders","parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","default":1,"title":"Page","minimum":1},"description":"1-based result page; each page contains at most 100 rows."},{"name":"PAYMENT-SIGNATURE","in":"header","required":false,"description":"Base64-encoded x402 v2 payment payload obtained after the initial HTTP 402 challenge.","schema":{"type":"string"}}],"responses":{"200":{"description":"Payment verified and settled; requested dataset page returned.","content":{"application/json":{"schema":{"type":"object","required":["source","total_rows","page","page_size","total_pages","rows"],"properties":{"source":{"type":"string"},"total_rows":{"type":"integer"},"page":{"type":"integer","minimum":1},"page_size":{"type":"integer","const":100},"total_pages":{"type":"integer","minimum":1},"rows":{"type":"array","maxItems":100,"items":{"type":"object","required":["id","title","entity","url"],"properties":{"id":{"type":"string"},"title":{"type":"string"},"entity":{"type":"string"},"procedure_type":{"type":"string"},"act_type":{"type":"string"},"base_price_eur":{"type":"string"},"published":{"type":"string"},"deadline":{"type":"string"},"url":{"type":"string"},"scraped_at":{"type":"string"}}}}}}}},"headers":{"PAYMENT-RESPONSE":{"description":"Base64-encoded x402 settlement response.","schema":{"type":"string"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}},"402":{"description":"Payment required or invalid. Decode PAYMENT-REQUIRED, sign the payment, and retry.","headers":{"PAYMENT-REQUIRED":{"description":"Base64-encoded x402 v2 payment requirements.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object"},"example":{}}}}},"description":"Returns up to 100 base.gov.pt tender notices per page. Requires x402 payment of $0.02 in USDC on Base mainnet.","tags":["Procurement"],"x-x402":{"version":2,"scheme":"exact","network":"eip155:8453","price":"$0.02","asset":"USDC","paymentHeader":"PAYMENT-SIGNATURE"},"x-mercado-price-micros":20000,"x-mercado-max-price-micros":20000}},"/v1/leads/porto":{"get":{"summary":"Porto real-estate agency leads","operationId":"getPortoLeads","responses":{"200":{"description":"Payment verified and settled; requested dataset page returned.","content":{"application/json":{"schema":{"type":"object","required":["source","total_rows","page","page_size","total_pages","rows"],"properties":{"source":{"type":"string"},"total_rows":{"type":"integer"},"page":{"type":"integer","minimum":1},"page_size":{"type":"integer","const":100},"total_pages":{"type":"integer","minimum":1},"rows":{"type":"array","maxItems":100,"items":{"type":"object","required":["uid","title","agency","phones_masked","url"],"properties":{"uid":{"type":"string"},"title":{"type":"string"},"price":{"type":"string"},"district":{"type":"string"},"lat":{"type":"string"},"lon":{"type":"string"},"agency":{"type":"string"},"agency_url":{"type":"string"},"agency_address":{"type":"string"},"phones_masked":{"type":"string"},"published":{"type":"string"},"days_on_air":{"type":"string"},"motivation_old":{"type":"string"},"url":{"type":"string"},"scraped":{"type":"string"}}}}}}}},"headers":{"PAYMENT-RESPONSE":{"description":"Base64-encoded x402 settlement response.","schema":{"type":"string"}}}},"402":{"description":"Payment required or invalid. Decode PAYMENT-REQUIRED, sign the payment, and retry.","headers":{"PAYMENT-REQUIRED":{"description":"Base64-encoded x402 v2 payment requirements.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object"},"example":{}}}}},"description":"Returns Porto property leads with agency details and masked phone numbers. Requires x402 payment of $0.05 in USDC on Base mainnet.","tags":["Leads"],"x-x402":{"version":2,"scheme":"exact","network":"eip155:8453","price":"$0.05","asset":"USDC","paymentHeader":"PAYMENT-SIGNATURE"},"x-mercado-price-micros":50000,"x-mercado-max-price-micros":50000,"parameters":[{"name":"PAYMENT-SIGNATURE","in":"header","required":false,"description":"Base64-encoded x402 v2 payment payload obtained after the initial HTTP 402 challenge.","schema":{"type":"string"}}]}},"/v1/leads/porto/phones":{"get":{"summary":"Porto agency leads with full phone numbers","operationId":"getPortoLeadPhones","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","required":["source","total_rows","page","page_size","total_pages","rows"],"properties":{"source":{"type":"string"},"total_rows":{"type":"integer"},"page":{"type":"integer","const":1},"page_size":{"type":"integer","const":100},"total_pages":{"type":"integer","minimum":1},"rows":{"type":"array","maxItems":100,"items":{"type":"object","required":["uid","agency","phones","url"],"properties":{"uid":{"type":"string"},"agency":{"type":"string"},"phones":{"type":"array","items":{"type":"string"}},"url":{"type":"string","format":"uri"}}}}}}}}}},"description":"Returns Porto agency leads including the complete phone numbers, for qualified B2B buyers.","tags":["Leads"],"x-mercado-price-micros":50000,"x-mercado-max-price-micros":50000}}},"components":{"schemas":{"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"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"}}},"servers":[{"url":"https://hermesportugal.duckdns.org/x402","description":"Public API through Nginx Proxy Manager"}],"tags":[{"name":"Real Estate","description":"Daily Portuguese property listings."},{"name":"Procurement","description":"Portuguese public procurement data."},{"name":"Leads","description":"Portuguese B2B real-estate leads."},{"name":"Service","description":"Public service metadata and health."}]}