diff --git a/2nd-gen/app-distribution-feedback-to-jira/README.md b/2nd-gen/app-distribution-feedback-to-jira/README.md new file mode 100644 index 0000000000..046f8865b2 --- /dev/null +++ b/2nd-gen/app-distribution-feedback-to-jira/README.md @@ -0,0 +1,31 @@ +# Send in-app feedback to Jira + +This [code](functions/index.js) demonstrates how to use a Firebase Cloud Function triggered by an +[in-app feedback Firebase Alert from App Distribution](https://firebase.google.com/docs/functions/beta/reference/firebase-functions.alerts.appdistribution.inappfeedbackpayload), +and stores the feedback details (including screenshot) in Jira. + +You can customize this code to work with your own Jira configuration (eg on-premise support, custom issue types, etc). + +## Quickstart + +This sample code uses Jira's built-in APIs to create issues for in-app tester feedback. For simplicity it uses [basic authorization](https://developer.atlassian.com/cloud/jira/platform/basic-auth-for-rest-apis/). + +1. [Generate an API token](https://id.atlassian.com/manage-profile/security/api-tokens) via your Jira profile. + + + Note: If the tester who files feedback does not have a Jira account, the user who generates this token will be marked as the issue's reporter. +2. This [code](functions/index.js) uses [parameterized configuration](https://firebase.google.com/docs/functions/config-env#params) to prompt for the required configuratio. To start the process, run: + ```bash + $ firebase deploy + ``` + This will store the `API_TOKEN` using [Google Cloud Secret Manager](https://cloud.google.com/secret-manager) and the remaining settings in an `.env` file which will contain the following variables, customized to your Jira project: + ```bash + JIRA_URI="" + PROJECT_KEY="" + ISSUE_TYPE_ID="" + ISSUE_LABEL="