Skip to content

Commit 5e04a7c

Browse files
authored
Merge branch 'main' into patch-1
2 parents e530a31 + 7805967 commit 5e04a7c

File tree

4 files changed

+28
-16
lines changed

4 files changed

+28
-16
lines changed

powerapps-docs/developer/data-platform/custom-api.md

Lines changed: 22 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,17 @@
11
---
22
title: "Create and use custom APIs (Microsoft Dataverse) | Microsoft Docs" # Intent and product brand in a unique string of 43-59 chars including spaces
3-
description: "custom API is a code-first way to define custom messages for Microsoft Dataverse" # 115-145 characters including spaces. This abstract displays in the search result.
3+
description: "Custom API is a code-first way to define custom messages for Microsoft Dataverse" # 115-145 characters including spaces. This abstract displays in the search result.
44
author: divkamath
55
ms.author: dikamath
6-
ms.date: 10/18/2023
6+
ms.date: 02/14/2024
77
ms.reviewer: jdaly
88
ms.topic: article
99
ms.subservice: dataverse-developer
1010
search.audienceType:
1111
- developer
1212
contributors:
1313
- JimDaly
14+
- SomaDaDe
1415
---
1516
# Create and use custom APIs
1617

@@ -24,7 +25,7 @@ Custom APIs are an alternative to custom process actions. Custom process actions
2425

2526
A custom API can include logic implemented with a plug-in. Using [Microsoft Dataverse business events](business-events.md), you can create a custom API without a plug-in to pass data about an event that other subscribers respond to.
2627

27-
However, in other cases you'll combine a custom API with a plug-in to define some operation that is delegated to Dataverse to compute and return the result.
28+
However, in other cases you combine a custom API with a plug-in to define some operation that is delegated to Dataverse to compute and return the result.
2829

2930
There are several different ways to create a custom API:
3031

@@ -64,20 +65,20 @@ More information [Managed properties](/power-platform/alm/managed-properties-alm
6465

6566
### Add more request parameters and response properties
6667

67-
Even when you have set the **Is Customizable** managed property to these components to `false`, new request parameters and response properties can be added to your custom API. However, these request parameters can't be made required. If you choose to allow custom processing steps on your custom API, other plug-ins registered for the message created by your custom API can use them. Because custom request parameters can only be optional, the plug-in you provide for the main operation of the custom API can ignore them and isn't responsible for using any custom request parameters or setting any custom response properties.
68+
Even when you set the **Is Customizable** managed property to these components to `false`, new request parameters and response properties can be added to your custom API. However, these request parameters can't be made required. If you choose to allow custom processing steps on your custom API, other plug-ins registered for the message created by your custom API can use them. Because custom request parameters can only be optional, the plug-in you provide for the main operation of the custom API can ignore them and isn't responsible for using any custom request parameters or setting any custom response properties.
6869

6970
## Custom API tables/entities
7071

71-
See [CustomAPI tables](custom-api-tables.md) for information about the tables and column values to use when creating Custom APIs.
72+
See [CustomAPI tables](custom-api-tables.md) for information about the tables and column values to use when creating custom APIs.
7273

7374

74-
## Select a Custom Processing Step Type
75+
## Select a custom processing step type
7576

7677
The following table describes which custom API **Custom Processing Step Type** (`AllowedCustomProcessingStepType`) you should use.
7778

7879
|Option |When to use |
7980
|---------|---------|
80-
|**None**|When the plug-in set for this custom API using [CustomAPI.PluginTypeId](reference/entities/customapi.md#BKMK_PluginTypeId) is the only logic that occurs when this operation executes.<br/>You won't allow another developer to register any more steps that can trigger other logic, modify the behavior of this operation, or cancel the operation.<br/>Use this option when the custom API provides some capability that shouldn't be customizable.|
81+
|**None**|When the plug-in set for this custom API using [CustomAPI.PluginTypeId](reference/entities/customapi.md#BKMK_PluginTypeId) is the only logic that occurs when this operation executes.<br/>You don't allow other developers to register any more steps that can trigger other logic, modify the behavior of this operation, or cancel the operation.<br/>Use this option when the custom API provides some capability that shouldn't be customizable.|
8182
|**Async Only**|When you want to allow other developers to detect when this operation occurs, but you don't want them to be able to cancel the operation or customize the behavior of the operation.<br/> Other developers can register asynchronous steps to detect that this operation occurred and respond to it after it has completed.<br/>This option is recommended if you're using the business events pattern. A business event creates a trigger in Power Automate to you can use when this event occurs. More information: [Microsoft Dataverse business events](business-events.md)|
8283
|**Sync and Async**|When you want to allow other developers to have the ability to change the behavior of the operation, and even cancel it if their business logic dictates.<br/>If the operation succeeds, other developers can also detect this event and add logic to run asynchronously.<br/>Most Dataverse messages enable extension in this manner. Use this option when your message represents a business process that should be customizable.|
8384

@@ -149,7 +150,10 @@ If you don't set the custom API **Plugin Type** (`PluginTypeId`) to specify mai
149150

150151
You might choose to not include any logic in the plug-in because you're using the custom API as a business event. More information: [Microsoft Dataverse business events](business-events.md).
151152

152-
You might not want to add a plug-in as a testing step. Without a plug-in, any output parameter values return the default values for the type because there's no code to set them.
153+
You might not want to add a plug-in as a testing step. Without a plug-in, any output parameter values return the default values for the type because there's no code to set them. Otherwise, see [Write a Plug-in for your custom API](#write-a-plug-in-for-your-custom-api)
154+
155+
> [!NOTE]
156+
> You can't pass configuration data to the plug-in specified for the main operation logic. [There is a workaround for this](#secure-and-unsecure-configuration-cant-be-set-for-the-custom-api-main-operation-plug-in).
153157
154158
## Use a custom API in a workflow
155159

@@ -260,7 +264,7 @@ The logic to be performed using a background operation must be defined as a cust
260264

261265
## Write a Plug-in for your custom API
262266

263-
Writing a plug-in to implement the main operation for your custom API isn't different from writing any other plug-in, except that you don't use the Plug-in Registration tool to set a specific step.
267+
Writing a plug-in to implement the main operation for your custom API isn't different from writing any other plug-in, except that you don't use the Plug-in Registration tool to set a specific step and [you can't specify configuration data to pass to the plug-in](#secure-and-unsecure-configuration-cant-be-set-for-the-custom-api-main-operation-plug-in).
264268

265269
You need to know the following information:
266270

@@ -465,7 +469,7 @@ More information:
465469

466470
## Known issues with custom APIs
467471

468-
Custom API is now generally available, but there are still some related capabilities that we expect to change.
472+
Custom APIs are now generally available, but there are still some related capabilities that we expect to change.
469473

470474
### Not able to use profiler for debugging
471475

@@ -477,6 +481,14 @@ To debug using the Plug-in Registration tool and the Plug-in profiler solution,
477481

478482
If you define your custom API to be private, you can't use that message in a plug-in. More information: [Private Messages](org-service/use-messages.md#private-messages)
479483

484+
### Secure and unsecure configuration can't be set for the custom API main operation plug-in
485+
486+
You can't pass [secure or unsecure configuration](write-plug-in.md#pass-configuration-data-to-your-plug-in) in to the main operation Plugin for the custom API.
487+
488+
**Workaround**: Rather than associate the plug-in with the custom API, register the plug-in on the `PostOperation` stage using the Plug-in Registration tool (PRT). This way, you can [specify configuration data in the `PostOperation` plug-in step as you usually do](register-plug-in.md#set-configuration-data).
489+
490+
To use this workaround, you must configure your custom API to enable **Sync and Async** [custom processing step types](#select-a-custom-processing-step-type) when you create the custom api. You can't change this after you create it.
491+
480492
### Next Steps
481493

482494
[Create a custom API using the plug-in registration tool](create-custom-api-prt.md)

powerapps-docs/developer/model-driven-apps/clientapi/reference/attributes/getRequiredLevel.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ title: "getRequiredLevel (Client API reference)| MicrosoftDocs"
33
description: Includes description and supported parameters for the getRequiredLevel method.
44
author: HemantGaur
55
ms.author: hemantg
6-
ms.date: 03/12/2022
6+
ms.date: 02/14/2024
77
ms.reviewer: jdaly
88
ms.topic: reference
99
applies_to: "Dynamics 365 (online)"
@@ -32,9 +32,9 @@ All
3232
**Type**: String.
3333

3434
**Description**: Returns one of the following values:
35-
- none
36-
- required
37-
- recommended
35+
- `none`
36+
- `required`
37+
- `recommended`
3838

3939
### Related article
4040

powerapps-docs/maker/TOC.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2583,7 +2583,7 @@
25832583
href: ../use-ai-builder.md
25842584
- name: Sample apps and solutions
25852585
items:
2586-
- name: Solution templates for Power Platform (preview)
2586+
- name: Enterprise templates for Power Platform
25872587
href: /power-platform/solution-templates/overview
25882588
- name: Crisis Communication
25892589
href: ./canvas-apps/sample-crisis-communication-app.md

powerapps-docs/maker/portals/portal-designer-anatomy.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ To open Power Apps portals Studio:
3030

3131
1. Go to **Active Sites** tab on [Power Pages](https://make.powerpages.microsoft.com).
3232

33-
1. On your site, select **More Commands**(...) for the site, then choose **Edit in Power Apps Sutdio**
33+
1. On your site, select **More Commands**(...) for the site, then choose **Edit in Power Apps Studio**
3434

3535
![Select Edit in Power Apps Studio to open the site in Power Apps Portals Studio.](media/manage-existing-portals/edit-in-power-apps.png "Select Edit in Power Apps Studio to open the site in Studio")
3636

0 commit comments

Comments
 (0)