---
schema_version: "1"
id: a43a1111bc495fe3578df1e4f5666df5fff07b32312d5cfa4fee81f248a274f4
title: data-code-extension script scan
collection: developer
version: current
locale: en-us
portal_url: https://docs.salesforce.com/developer/current/en-us/data-cloud/data-cloud-code-ext/guides/cli-reference/data-code-extension-script-scan.md
canonical_url: https://developer.salesforce.com/docs/data/data-cloud-code-ext-cli-reference/guide/data-code-extension-script-scan.html
source_site: developer.salesforce.com
content_type: documentation
content_hash: 49aa9d46e3112c269cf29f6c0b578541247b72c11e27c91279ff46c0857307a7
products:
  - Data 360 Code Extension CLI Reference
  - Data 360 Developer Documentation
---
# data-code-extension script scan

Scan a data code extension script package for permissions and dependencies.

## Description

Scan the Python entrypoint file in an initialized data code extension script package to identify required permissions and dependencies. By default, this command updates `config.json` and `requirements.txt` based on the scan results.

## Examples

Scan with a custom entrypoint file:

```sh
sf data-code-extension script scan --entrypoint ./my-script-package/payload/entrypoint.py
```

Perform a dry run to preview the changes:

```sh
sf data-code-extension script scan --entrypoint ./my-script-package/payload/entrypoint.py --dry-run
```

Scan without updating `requirements.txt`:

```sh
sf data-code-extension script scan --entrypoint ./my-script-package/payload/entrypoint.py --no-requirements
```

## Flags

- `-e, --entrypoint <ENTRYPOINT>` (Optional): Path to the entrypoint Python file to scan.
- `--config-file <CONFIG-FILE>` (Optional): Path to an alternate configuration file.
- `-d, --dry-run` (Optional): Preview changes without modifying files.
- `-n, --no-requirements` (Optional): Skip updates to `requirements.txt`.
- `--flags-dir <FLAGS-DIR>` (Optional): Global flag that provides command flag values from files in a directory instead of passing them on the command line. Name each file in the directory after a supported flag of the command, without the `-- ` prefix, and include the plain text value for that flag as its content. Omit required flags from the command line if they are satisfied through the directory.
