Getting started
- A company administrator opens Empresa › Integraciones in the application (the application is in Spanish) and creates an integration.
- The administrator grants authorized data by domain and field group. The
confidentialandpeoplegroups require explicit confirmation. - For webhooks, create a destination with an HTTPS URL and copy the signing secret, which is shown only once. For the API, create an OAuth 2.0 client or an API key.
- Send the test event, verify the signature at the receiver and activate the destination.
Permissions belong to the company and can be revoked at any time; on revocation the API responds 403 immediately and pending deliveries are cancelled.
Reference
| Section | Content |
|---|---|
| Webhooks | Envelope, headers, signature, retries, ordering, idempotency and authentication toward your receiver. |
| Data API | OAuth 2.0 tokens, scopes, resources, cursor pagination, catalog and client and portfolio operations, quotas and errors. |
| Communications | Publications and highlights from a company system: grant, routes, external identity, revisions, states, content, limits and errors. |
| Surveys | Definitions, campaigns and aggregated results: grant, previews, approval, campaign lifecycle, limits and errors. |
| Event catalog | Each event type, its domain and its JSON Schema. |
| System guides | SAP Integration Suite, MuleSoft, Boomi, Azure Logic Apps, Power Automate, Dynamics 365, Salesforce, HubSpot, n8n, Make, Zapier, and signature verification in Node.js, Python, Java and C#. |
| Errors | One document for each API error code. |
| Security | Security evaluation package, with a downloadable PDF. |
URLs that Masnet emits
The following addresses appear in deliveries and API responses and resolve to this documentation:
| Where it appears | Address |
|---|---|
dataschema member of the envelope | https://masnet.com/developers/schemas/<object>/v1.json |
| Envelope schema | https://masnet.com/developers/schemas/envelope/v1.json |
type member of an error | https://masnet.com/developers/errors/<code> |
User-Agent header of webhooks | Masnet-Webhooks/1.0 (+https://masnet.com/developers/webhooks) |
Versions and compatibility
Current contract version: 1.7.0 (2026-11-27), digest sha256:18057f386936a73a1394c8673b25d687b18ab58a85d558d13c8d3d32632dc3b3. The same information, with the full history, is at /developers/contract.json for systems and agents that compare versions.
- The contract follows SemVer: major if a receiver that meets the contract stops working, minor if something is added, patch if something is fixed without changing the shape. Each published version keeps its digest.
- The major version appears in the event type (
.v1), in the API path (/v1) and in the schemas. - Within a major version the following are compatible: new optional fields, new event types and new values in open enumerations. Write your receiver to ignore what it does not know.
- An incompatible change creates a new major version that is published in parallel.
Contract changelog
1.7.0 · 2026-11-27
buyersdomain (Mercado Público buyer master) with itsread:buyersscope. It is read only and its data grant accepts only thepublicfield group: a grant with another group responds 422field_group_not_available. It can be granted by whoever can view Tenders in the company.GET /data/buyersreturns the whole master, one row per branch (purchasing unit), withid(the samebuyer.ideach client carries),rut,name(the organization),branch_name(the branch, null when it repeats the organization name),region(the short region, such asV VALPARAISOorMETROPOLITANA) andcommune.regionandcommuneare null when the source does not report them. It is ordered by update time with the data API cursor and accepts onlyupdated_since: it has no filters, no search and noGET /data/buyers/{id}, which responds 404. The receiver filters its own copy. It has no events.client-operationsaccepts theid_unidadcolumn, with theidfromGET /data/buyers, in theClientes,Grupo_Miembros,Cartera_ClientesandAsignacionessheets. A row names the branch byid_unidador, as before, byrutandcodigo_unidad(orcliente_refinClientes). When it carries both and they are not the same branch, the row is rejected withbuyer_mismatchin theid_unidadcolumn; anid_unidadthat does not exist in the master, withbuyer_not_foundin the same column. Each<sheet>.id_unidadpath is granted likecodigo_unidadin that sheet.- The
commercial-portfolios-exchange/v1.jsonschema adds the optionalid_unidadcolumn to those four sheets and the field registry moves to version 2. A body valid in 1.6.0 is still valid.
1.6.0 · 2026-11-27
- Framework agreement price requests: the
com.masnet.framework_agreement_price_request.requested.v1event (price_requestsdomain,subjectframework_agreement_price_request/{id}) carries aframework-agreement-price-request.v1request indata.object: the framework agreement, one row per product and region with its base price, its active or scheduled offer, the store minimum start date and day range, and up to 200 rows, withtruncatedand thelinks.self,links.rowsandlinks.responselinks. Only the integration the company designated as its framework agreement channel receives it, at the endpoint subscribed to that type, and delivery is not attempted afterrespond_by. - The framework agreement channel is its own designation, independent of the tender channel: it can be the same integration or another one. Both use the
price_requestsgrant, which the first designation grants and which is revoked only when the integration is no longer the channel of either. GET /data/framework-agreement-price-requests/{id}returns the request with its status and, once answered,responded_atandrows_received.GET /data/framework-agreement-price-requests/{id}/rowsreturns every row, 1,000 per page by default and at most 5,000 (limit), in product and region order, withnext_cursor. A request of another integration responds 404.POST /data/framework-agreement-price-requests/{id}/responsereceives theframework-agreement-price-response.v1answer (the columns of the offer spreadsheet:sku,region,price,start_dateanddays, up to 50,000 rows) with a mandatoryIdempotency-Keyheader and a body of at most 4 MiB. The server validates only the shape; the person reviews the business rules in Masnet before the offers are loaded. It responds 200 withstatus: receivedandrows_received(replayed: truewhen the same content is repeated), 400PRICE_RESPONSE_INVALID, 404, 409PRICE_REQUEST_NOT_AWAITING,PRICE_REQUEST_EXPIREDorPRICE_RESPONSE_CONFLICT, 413, or 503 withRetry-Afterwhen nothing was stored.- Framework agreement test request: the
com.masnet.integration.test.v1test event can carry a fixed-content request with idtest_<32 hex>andframework-agreement-price-requestslinks. Its answer is validated against the same schema and respondsstatus: validated,test: trueandrows_received; nothing is stored. - The
framework-agreement-price-request/v1.json(the request) andframework-agreement-price-response/v1.json(the answer and its result) schemas are published.framework_agreement_price_request/v1.json, the eventdataschema, describes itsdata, whoseobjectis that same request. - Administration:
PUT /integrations/{id}/price-request-channelandPOST /integrations/{id}/price-request-testsacceptscope(tenderby default orframework_agreement), and the integration detail addsframework_agreement_price_request_channelandframework_agreement_price_request_test, with the same shape as their tender counterparts. Withoutscope, everything responds as in 1.5.0. - Events API: a routed event (tender and framework agreement price requests) is readable only by the integration it is routed to.
GET /data/eventsdoes not list it for another integration of the company, even with theprice_requestsdomain, andGET /data/events/{id}responds 404, the same as a nonexistent event. Non-routed events do not change.
1.5.0 · 2026-11-26
- Domains
clients(clients and client groups),sales_portfolios(portfolios, sales scopes and assignments) andbusiness_lines(business lines), with theirread:clients,read:sales_portfoliosandread:business_linesscopes and, for the first two,write:clientsandwrite:sales_portfolios. Asales_portfolioswrite grant requires thepeoplefield group. - Resources
GET /data/clients,client-groups,sales-portfolios,sales-scopes,client-assignments,product-groups,competitor-marksandbusiness-lines, each with its read by id, and the member listsGET /data/client-groups/{id}/clientsandGET /data/sales-portfolios/{id}/clients(onlylimitandcursor).client-assignmentsdoes not acceptupdated_since;business-lineshas soft deletion. - Eleven commercial event types:
client.added,client.updated,client.archived,client.reactivated,client_group.changed,sales_portfolio.changed,sales_scope.changed,client_assignment.changed,product_group.changed,competitor_mark.changedandbusiness_line.changed.sales_scope.changedandclient_assignment.changedrequire thepeoplegroup. POST /data/client-operationswrites clients, groups, portfolios and assignments with thecommercial-portfolios-exchange.v1body (the sheets and columns of the Clients spreadsheet, up to 100,000 rows) and responds 202 with thecommercial-operation.v1operation. The cycle continues withGET /data/client-operations/{id},POST .../apply(withvalidation_token, production only),POST .../cancelandGET .../results. TheAlcancesheet is governed by Masnet and responds 403field_path_not_granted. Thecommercial-portfolios-exchange/v1.jsonandcommercial-operation/v1.jsonschemas are published.catalog-itemsaddsgroup_idsandprimary_group_id. The groups of a product are still written with themembershipsofcatalog-exchange.v1underwrite:catalog, andcatalog_item.updatedis also emitted when they change.catalog_item.deactivatedno longer comes with acatalog_item.updatedwith the samesequence: a deactivation with other changes emits onlydeactivated, with every changed field.GET /integrations/catalog(administration):capture_enabledreports the capture switch of the type, as its name says, and the newsend_enabledfield reports the send switch. Before,capture_enabledreported the send switch.
1.4.0 · 2026-11-24
- Awards (
GET /data/awardsand theaward.*events): the newunit_pricesfield (businessgroup) istruewhen the award has at least one unit price line with an open quantity, that is, the award resolution sets the unit price but not the quantity. In that caseawarded_netis not the contract total. awarded_netadds up the contract amount of each line as the award resolution declares it; a unit price line with an open quantity contributes the amount of the Mercado Público record. Before, it always added up the record amount. A change ofunit_pricesorawarded_netincrementsversion.
1.3.0 · 2026-11-17
- Price requests: the
com.masnet.price_request.requested.v1event carries aprice-request.v1request indata.object(tender, bid and up to 200 lines, withtruncatedand thelinks.self,links.linesandlinks.responselinks). Only the integration the company designated as its price request channel receives it, at the endpoint subscribed to that type, and delivery is not attempted afterrespond_by. - Domain
price_requestswith theread:price_requestsandwrite:price_requestsscopes. Designating the channel (with a second factor) grants it and withdrawing the channel revokes it; it is not granted throughPUT /integrations/{id}/grants. GET /data/price-requests/{id}returns the request with its status and, once applied,summaryandresults.GET /data/price-requests/{id}/linesreturns every line, 500 per page in item order, withnext_cursor. A request of another integration responds 404.POST /data/price-requests/{id}/responsereceives theprice-response.v1answer with a mandatoryIdempotency-Keyheader and a body of at most 4 MiB. It responds 200 with the per-line result (applied in the same transaction or, when the same content is repeated, the stored one withreplayed: true), 400PRICE_RESPONSE_INVALID, 404, 409PRICE_REQUEST_NOT_AWAITING,PRICE_REQUEST_EXPIREDorPRICE_RESPONSE_CONFLICT, or 503 withRetry-Afterwhen nothing was applied.- Test request: the
com.masnet.integration.test.v1test event can carry a fixed-content request with idtest_<32 hex>. Its answer is validated with the same rules and respondsstatus: validatedandtest: true; it never changes a bid. - The
price-request/v1.json(the request) andprice-response/v1.json(the answer and its result) schemas are published.price_request/v1.json, the eventdataschema, describes itsdata, whoseobjectis that same request.
1.2.2 · 2026-11-17
- Bid lines (
lines[]inGET /data/bidsand in the fourbid.*events) carry the product code incatalog_item.code, as the contract documents. Before, they only carriedcatalog_item.id.codeisnullwhen the product has no code, andcatalog_itemstaysnullwhen the line has no product. catalog_item.idin those lines is decimal text, as thebidschema declares and like theidofGET /data/catalog-items/{id}. It was sent as a number.
1.2.1 · 2026-11-06
GET /data/opportunities?tender_code=responds 200 with the opportunities of that tender, ordata: []when there are none. In a company with many tenders it responded 503temporarily_unavailableeven when the code existed.
1.2.0 · 2026-11-05
PUT /integrations/{id}/grantsrequiresconfirm_groupsonly for the sensitive groups the change adds to a domain. Resendingconfidentialorpeoplealready granted no longer asks for confirmation again.- The data API responds only with the per-client quota headers (
RateLimit-Policy: 600;w=60andRateLimit). An authenticated client no longer consumes the general per-IP limit. - A catalog operation that is
invalidbecause the whole file was rejected reports its reason infailure(code,retryable: false). - In the
catalog-exchange.v1package,product_refis optional inProducts: it only links the row to its relations. A duplicated or malformed reference invalidates only that row. - The
catalog-exchange/v1.jsonandcatalog-operation/v1.jsonschemas are published, along with the Audit response shape and continuation rule.
1.1.0 · 2026-11-05
opportunity.createdis sent on the first management act (owner, decision, stage, business line, company tag or company checklist). Reading, starring, following or moving to a folder no longer creates the opportunity.- New
opportunity.business_line_changed,opportunity.tags_changedandopportunity.preparation_changed. - The opportunity publishes
managed_at,tags(company tags only) andpreparation(counts of the company checklists, without text). GET /data/opportunitiesand thetender.*events cover only tenders under management.
1.0.0 · 2026-11-04
- Contract in force before F6: signed webhooks, data API, event log and write APIs for catalog, prices, Communications and Surveys.
Support and contact
For technical questions write to [email protected] and include the correlation_id of the response or the webhook-id of the event. Report vulnerabilities to [email protected], according to Annex B of the Complementary Annexes (published in Spanish).