--- title: app function replay description: Runs the function from your current directory for [testing purposes](/docs/apps/functions/testing-and-debugging). To learn how you can monitor and debug functions when errors occur, refer to [Shopify Functions error handling](/docs/api/functions/errors). api_name: shopify-cli source_url: html: https://shopify.dev/docs/api/shopify-cli/app/app-function-replay md: https://shopify.dev/docs/api/shopify-cli/app/app-function-replay.md --- # app function replaycommand Runs the function from your current directory for [testing purposes](https://shopify.dev/docs/apps/functions/testing-and-debugging). To learn how you can monitor and debug functions when errors occur, refer to [Shopify Functions error handling](https://shopify.dev/docs/api/functions/errors). ## Flags The following flags are available for the `app function replay` command: * \--client-id \ string env: SHOPIFY\_FLAG\_CLIENT\_ID The Client ID of your app. * \--no-color env: SHOPIFY\_FLAG\_NO\_COLOR Disable color output. * \--path \ string env: SHOPIFY\_FLAG\_PATH The path to your function directory. * \--reset env: SHOPIFY\_FLAG\_RESET Reset all your settings. * \--verbose env: SHOPIFY\_FLAG\_VERBOSE Increase the verbosity of the output. * -c, --config \ string env: SHOPIFY\_FLAG\_APP\_CONFIG The name of the app configuration. * -j, --json env: SHOPIFY\_FLAG\_JSON Output the result as JSON. * -l, --log \ string env: SHOPIFY\_FLAG\_LOG Specifies a log identifier to replay instead of selecting from a list. The identifier is provided in the output of `shopify app dev` and is the suffix of the log file name. * -w, --watch env: SHOPIFY\_FLAG\_WATCH Re-run the function when the source code changes. ### Examples * #### app function replay ##### app function replay ```bash shopify app function replay [flags] ```