Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
(Preview) Commands to manage your Code apps.
Pac code commands support Power Apps capabilities that are only available in an early access preview. You can request to participate in the the early access preview by signing up with the following form: https://aka.ms/paCodeAppsEAP.
Commands
| Command | Description |
|---|---|
| pac code add-data-source | (Preview) Adds a new datasource to the app. |
| pac code delete-data-source | (Preview) Deletes a data source from the current app. |
| pac code init | (Preview) Initializes a Code app in the current directory. |
| pac code list | (Preview) Lists the code apps available in the current environment. |
| pac code list-connection-references | (Preview) Lists connection references in the specified environment and solution. |
| pac code list-datasets | (Preview) Lists datasets accessible by the provided connector. |
| pac code list-sql-stored-procedures | (Preview) Lists stored procedures accessible by the provided SQL connection and dataset. |
| pac code list-tables | (Preview) Lists tables accessible by the provided connector and dataset. |
| pac code push | (Preview) Publishes a new version of a Code app. |
| pac code run | (Preview) Runs a local server for connections loading locally in the app. |
pac code add-data-source
(Preview) Adds a new datasource to the app.
Required Parameters for code add-data-source
--apiId -a
The api id of the datasource.
Optional Parameters for code add-data-source
--connectionId -c
The connection id of the datasource.
--connectionRef -cr
The connection reference ID.
--dataset -d
The dataset name of the datasource.
--environment -env
The environment URL to connect to the data source.
--logLevel -l
The logging level for the command.
--solutionId -s
The solution ID of the connection reference. Used only when connection reference parameter is present.
--storedProcedure -sp
The stored procedure name to add (only supported for shared_sql).
--table -t
The table name of the datasource.
pac code delete-data-source
(Preview) Deletes a data source from the current app.
Required Parameters for code delete-data-source
--apiId -a
The api id of the datasource.
--dataSourceName -ds
The name of the data source to delete.
Optional Parameters for code delete-data-source
--storedProcedure -sp
The stored procedure name to remove from the app.
pac code init
(Preview) Initializes a Code app in the current directory.
Required Parameters for code init
--displayName -n
The display name of the Code app.
Optional Parameters for code init
--appUrl -a
The local url the app is running on.
--buildPath -b
The directory of your apps build assets.
--description -d
The description of the Code App.
--environment -env
Specifies the target Dataverse. The value may be a Guid or absolute https URL. When not specified, the active organization selected for the current auth profile will be used.
--fileEntryPoint -f
The entry point for the app to load from.
--logoPath -l
The path to the logo file for the app.
pac code list
(Preview) Lists the code apps available in the current environment.
pac code list-connection-references
(Preview) Lists connection references in the specified environment and solution.
Required Parameters for code list-connection-references
--solutionId -s
The ID of the solution to list connection references from.
Optional Parameters for code list-connection-references
--environment -env
The environment URL to list connection references from. If not provided, uses the current environment.
pac code list-datasets
(Preview) Lists datasets accessible by the provided connector.
Required Parameters for code list-datasets
--apiId -a
The api id of the datasource.
Optional Parameters for code list-datasets
--connectionId -c
The connection id of the datasource.
pac code list-sql-stored-procedures
(Preview) Lists stored procedures accessible by the provided SQL connection and dataset.
Optional Parameters for code list-sql-stored-procedures
--connectionId -c
The connection id of the datasource.
--dataset -d
The dataset name of the datasource.
pac code list-tables
(Preview) Lists tables accessible by the provided connector and dataset.
Required Parameters for code list-tables
--apiId -a
The api id of the datasource.
Optional Parameters for code list-tables
--connectionId -c
The connection id of the datasource.
--dataset -d
The dataset name of the datasource.
pac code push
(Preview) Publishes a new version of a Code app.
Optional Parameters for code push
--environment -env
Specifies the target Dataverse. The value may be a Guid or absolute https URL. When not specified, the active organization selected for the current auth profile will be used.
--solutionName -s
The Solution Name for the code app to associate with.
pac code run
(Preview) Runs a local server for connections loading locally in the app.
Optional Parameters for code run
--appUrl -a
The local url the app is running on.
--port -p
The port to run the local server on.
See also
Microsoft Power Platform CLI Command Groups
Microsoft Power Platform CLI overview