Edit

Share via


pac code

(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 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.

--connectionId -c

The connection id of the datasource.

Optional Parameters for code add-data-source

--dataset -d

The dataset name of the datasource.

--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 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.

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