Logic API
Actions
Configure the read, create, update, delete, upload and download actions of an entity, step by step.
Actions are the endpoints that work with records of one entity. You configure each action in a short series of steps: what it is called, what callers send, what data it looks up first, who may call it, and which fields it reads or writes. This page covers the record actions; for actions that run a Dataverse action, see Processes.
Add an action
Section titled “Add an action”- In the tree, open the module, then the entity.
- Select the kind of action, for example Add read action or Add create action.
- Work through the steps in the editor. Steps with a problem are flagged; the issues list takes you straight to them.
- Save with Ctrl+S.
Steps every action has
Section titled “Steps every action has”| Step | What you set | Notes |
|---|---|---|
| Definition | The action’s Action Name. | 3–50 letters and numbers, starting with a letter. It becomes the last segment of the address, in lowercase. |
| Docs | A title and description. | Write them for the developers who call the API. |
| Input | The arguments callers send. | See Inputs. |
| Data Fetcher | Queries that run before the action. | Their results are available to the precondition and to field bindings. For example, look up the case’s current status before allowing an update. |
| Access Control | An Authorization Policy and a Precondition. | See Access control. Without an authorization policy the action is public. |
Inputs
Section titled “Inputs”Each input has a name and a type. The types you can choose include String, True/False, DateTime, Decimal, Currency, Double, Integer, Unique Identifier, Entity Reference and option sets. Date and time inputs also have a DateTime Behavior: User Local, Time Zone Independent or Date Only.
Depending on the type, you can also make an input required, give it a default value, and set limits such as minimum and maximum values, lengths or list sizes. Callers that send an input that is missing or outside its limits get an ARGUMENT_VALIDATION_ERROR; see Responses and errors.
Action settings
Section titled “Action settings”| Action | Extra settings | Address and method |
|---|---|---|
| Read | The Properties (fields) to return. Retrieve Attachment List adds the record’s attachments to the response. | GET /{module}/{entity}/{id}/{action} |
| Create | Entity Properties: which fields to set, and from which input or fetched value. | POST /{module}/{entity}/{action} |
| Update | Entity Properties: which fields to change. Only the fields you bind are written. | PUT /{module}/{entity}/{id}/{action} |
| Delete | — | DELETE /{module}/{entity}/{id}/{action} |
| Upload | Max File Size in Kb, Allowed File Extensions, Attachment Name, Allow Multiple. | POST /{module}/{entity}/{id}/{action} |
| Download | — | GET /{module}/{entity}/{id}/{action}/{attachmentId} |
{entity} is the table’s logical name, {id} the record’s unique identifier, and {action} the action name, all in lowercase.
How it behaves
Section titled “How it behaves”- Order of checks. For each call, the inputs are validated, the data fetchers run, then the authorization policy and the precondition are checked. Only if everything passes does the action read or write Dataverse.
- Read returns
404 Not Foundwhen the record does not exist. Lookups are returned as an object with the related record’sidandname. - Create returns the new record’s
id. Update and Delete return200 OKwith an empty body. - Upload accepts one file per call, sent as
multipart/form-datain a field namedfile. The limits you set (size, extensions, single or multiple attachments) apply. - Download returns the file itself, with its content type and file name. A missing attachment returns
404 Not Found. - Dataverse rules still apply. Business rules, plug-ins, flows and Logic Fabric recipes on the table run as usual when an action writes a record. If Dataverse rejects the operation, the caller gets an error.
Example: let customers update their case
Section titled “Example: let customers update their case”A portal lets customers change the description of their own open cases.
| Step | Setting |
|---|---|
| Definition | Action name update on entity incident in module Service → PUT /service/incident/{id}/update |
| Input | description (String, required, maximum length 2000) |
| Data Fetcher | Look up the case’s status and customer. |
| Access Control | Demand Authenticated User; precondition: the case is active and belongs to the signed-in contact, with the message “You can only change your own open cases.” |
| Entity Properties | description ← input description |
PUT /service/incident/3f2a9c1e-5b7d-4e8a-9f10-2c3d4e5f6a7b/updateAuthorization: Bearer eyJ0eXAiOi...Content-Type: application/json
{ "description": "The replacement router also fails after 10 minutes." }The API answers 200 OK with an empty body.