Connect a service to Power Automate, Logic Apps and Power Apps

Updated 2026-11-13

How to run a calculation of your service in a Power Automate flow: import the SpreadAPI custom connector once, then use the Calculate action with the ID of your service. The same connector works in Logic Apps and Power Apps.

What you get

SpreadAPI provides a custom connector for the Microsoft Power Platform. It has one action, Calculate. You enter the ID of a service, and the action shows that service's inputs as fields: lists for allowed values, number and yes/no fields, and marks for required inputs. The results come back as named fields that later steps of your flow can use.

Power Automate works differently from n8n and Zapier in one point: you import one connector for all your services, and each Calculate action names its service by ID.

Before you start

  • The service must be published. Until then the setup page says "Publish the service before you connect it to Power Automate."
  • If the service requires a token, have a token ready. A token is shown only once, when it is created; create one under API → Access (Zugriff). See Tokens and access.

Get the connector address and the service ID

  1. Open your service and open API → Automation → Power Automate (Automatisierung).
  2. The page offers two values, each with a Copy (Kopieren) button:
FieldWhat it isHow often you need it
Connector (import once) (Connector (einmal importieren))The address of the connector definitionOnce per Power Platform environment
Service ID (for every Calculate action) (Service-ID (für jede Calculate-Aktion))The ID of this serviceIn every Calculate action that should call this service

The connector address is the same for every service:

https://spreadapi.io/integrations/power-automate/spreadapi.swagger.json

Set up in Power Automate

The names of Power Automate's own menus are given as Power Automate shows them.

  1. Import the connector (once). Open *Data → Custom connectors → New custom connector → Import an OpenAPI from URL*, paste the connector address and create the connector.
  2. Add the Calculate action to your flow. In the flow designer add an action, search for SpreadAPI and choose *Calculate*.
  3. Connect and enter the Service ID. Create a connection. The connection asks for a Service token: for a protected service enter Bearer YOUR_TOKEN_HERE, that is the word Bearer, a space, and your token. Then paste the Service ID.
  4. Fill in the fields and run. The service's inputs appear as fields, with lists, numbers and required marks. Set the values and run; the results are available to later steps.

For a public service the token is not checked. Power Automate still wants a value in the field, so enter any text.

Using the results

After the Calculate action, later steps can pick these values:

  • Result: every output of your service as its own named field with the right type. This is what you normally use.
  • Service name and Service ID.
  • Execution time (ms) and From cache.
  • Outputs (raw list), under the advanced fields: the same results as a list of name, label and value.

An output that is a cell range comes back as a list inside its Result field.

Good to know

  • One connector, all services. Import it once; each Calculate action picks its service by ID.
  • One connection per protected service. A token belongs to one service. If you call several protected services, create one connection for each, with that service's token.
  • Percentages are decimals. Send 5% as 0.05. See Percentages and formats.
  • Logic Apps and Power Apps. The same custom connector works there too.
  • After changes to the service. When you add, rename or remove inputs or outputs and publish again, open the Calculate action in the designer so it loads the fields again, and check your mappings.

When something goes wrong

What you seeWhat to do
No input fields appear after you enter the Service IDCheck the ID and that the service is published. For a protected service, check that the connection's token is entered as Bearer YOUR_TOKEN_HERE and belongs to this service
The action fails with status 400The message names the reason: a missing or invalid input, or a missing, wrong or expired token. See Error reference
The action fails with status 404The service ID is wrong or the service is not published
The action fails with status 429Too many calls per minute, or the month's calls are used up. See Limit errors

Limits

  • The connector offers the Calculate action. It has no trigger: a flow cannot start because something happened in SpreadAPI.
  • The connector calls services on spreadapi.io.
  • Each run of the action is one call of your service. It counts toward the calls of your plan, and a service takes at most 1,000 calls per minute. See Call limits.

For developers and agents

Connector definition (OpenAPI 2.0):

https://spreadapi.io/integrations/power-automate/spreadapi.swagger.json
ItemValue
ActionCalculate = POST https://spreadapi.io/api/v1/services/{serviceId}/execute?flatten=true
Body{"inputs": {"<input name>": <value>, …}}
AuthenticationAPI key in the header Authorization, value Bearer {token}
Input fieldsLoaded from GET /api/v1/services/{serviceId}/input-schema
Result fieldsLoaded from GET /api/v1/services/{serviceId}/output-schema

The two schema addresses return a JSON Schema wrapped in schema:

{
  "schema": {
    "type": "object",
    "properties": {
      "amount": { "type": "number" },
      "region": { "type": "string", "enum": ["EU", "US"] }
    },
    "required": ["amount"]
  }
}
  • input-schema: one property per input, by input name; required lists the required inputs.
  • output-schema: one property per output, by output name.
  • Both answer 404 for a service that is not published. For a protected service they need the token as Authorization: Bearer {token} or ?token={token} and answer 401 without a valid one.
  • With flatten=true the answer of the call contains result, an object with one entry per output name, in addition to service, inputs, outputs and metadata. See The API response.

FAQ

How do I use my service in Power Automate?

Import the connector once from https://spreadapi.io/integrations/power-automate/spreadapi.swagger.json under *Data → Custom connectors*. Then add the action SpreadAPI → Calculate to your flow, create a connection and enter the Service ID.

Where do I find the Service ID?

In your service under API → Automation → Power Automate, in the field Service ID (for every Calculate action). Copy it with the Copy button.

What do I enter as the token in the Power Automate connection?

For a protected service, enter Bearer YOUR_TOKEN_HERE: the word Bearer, a space, then the token. For a public service the value is not checked, so any text works.

Do I have to import the connector for every service?

No. You import the connector once, and every Calculate action chooses its service through the Service ID.

Why do no input fields appear in the Calculate action?

The fields are loaded from the published service. Check that the Service ID is correct, that the service is published, and for a protected service that the connection holds Bearer YOUR_TOKEN_HERE with a token of this service.

How do I use the calculated values in later steps?

Pick them from Result in the dynamic content: each output of your service is a named field there. The raw list of outputs is available under the advanced fields.

Does the connector work in Logic Apps and Power Apps?

Yes. The same custom connector works in Power Automate, Logic Apps and Power Apps.

Can I call several services from one flow?

Yes. Add one Calculate action per service and enter the Service ID of each. Protected services each need their own connection, because a token belongs to one service.

I changed the inputs of my service. What do I do in my flow?

Publish the service again, then open the Calculate action in the designer so it loads the fields again. Check the values and mappings before you run the flow.

As an agent, how do I read the input fields a service expects?

Call GET https://spreadapi.io/api/v1/services/{serviceId}/input-schema, with Authorization: Bearer {token} for a protected service. The answer is {"schema": {"type": "object", "properties": {…}, "required": […]}}, keyed by input name.

As an agent, how do I get results keyed by name instead of a list?

Add ?flatten=true to the POST call. The answer then contains result, an object with one entry per output name.