Open API and Swagger

Integrate your brand’s materials and prices with personal tokens that expire and can be revoked.

  1. Create a token

    In Settings → Open API, choose the active brand, name, expiration, and read or write permissions for Materials and Pricing. Copy the token shown once.

  2. Try Swagger

    Open https://api.metriplan.com/api-docs?lang=en, click Authorize, and paste the mpat_ token (without typing Bearer). Expand a route, fill its fields, and click Execute.

  3. List materials in a folder

    GET /api/public/v1/materials accepts folder_path with a logical folder path such as MATERIA_PRIMA\MDF\Duratex. The response includes descendants and their budget codes.

  4. Update codes and prices

    PATCH /materials/{id}/budget-code sets a code. GET /raw-materials/{moduleId}/variations lists available SKUs. PUT /variations/prices accepts up to 100 codes per call; use unit un for units or m2 for square metres, and price in BRL.

  5. Protect access

    Store the token as a server-side secret. It is limited to its brand, the creator’s current permissions, and the chosen scopes. Revoke it in Settings when no longer needed.