Connect Amazon Q Developer to LinearB
Connect Amazon Q Developer to LinearB through AWS to collect adoption and accepted-lines data from Amazon Q usage reports.
Before You Begin
Verify that you have:
- Access to AI Tools settings in LinearB.
- AWS administrative access to IAM, S3, and IAM Identity Center.
- An active Amazon Q Developer environment.
- Amazon Q Developer user activity reports enabled.
- The S3 bucket and path where Amazon Q Developer reports are exported.
- The IAM Identity Center instance used by Amazon Q Developer.
Prepare Amazon Q Developer Reporting in AWS
Before connecting Amazon Q Developer to LinearB, enable user activity reports and configure an S3 bucket as the report destination.
- Open the Amazon Q Developer administration environment.
- Enable user activity reports.
- Configure the S3 bucket and prefix where Amazon Q Developer reports will be exported.
- Optionally enable prompt logging.
- Confirm that Amazon Q Developer usage reports are being generated in the configured S3 location.
Create the IAM Role for LinearB
Create a cross-account IAM role that LinearB can use to access the Amazon Q Developer reports and resolve users.
- In the AWS console, go to IAM → Roles.
- Click Create role.
- For Trusted entity type, select AWS account.
- Select Another AWS account.
-
Enter the LinearB AWS account ID:
841492816024
- Continue without attaching permissions to the role.
-
Enter a role name that starts with
LinearB. - Create the role.
LinearB. LinearB can only assume roles that use this prefix.
Do not manually configure the final permissions or External ID yet. LinearB generates the required policies after you enter the AWS settings in the connection wizard.
Start the Connection in LinearB
- Go to Settings → Company Settings → AI Tools → Integrations.
- Click Add New.
- Select AWS.
- Click Continue.
- Select Amazon Q Developer.
- Click Continue.
Enter the AWS Main Settings
Enter the five AWS values requested by the LinearB connection wizard.
IAM Role ARN
Use the ARN of the IAM role you created for LinearB.
- In AWS, go to IAM → Roles.
- Open the
LinearBrole you created. - Find the ARN in the Summary at the top of the page.
- Copy the ARN and paste it into IAM Role ARN in LinearB.
Usage Data S3 Path
Use the S3 location where Amazon Q Developer exports its usage reports.
- In AWS, go to S3 → Buckets.
- Open the reporting bucket.
- Open the folder or prefix containing the Amazon Q Developer reports.
- Use Copy S3 URI.
-
Paste the URI into Usage Data S3 Path in LinearB.
The value should look similar to:
s3://bucket-name/report-prefix
Identity Store ID
Use the Identity Store ID for the IAM Identity Center whose users sign in to Amazon Q Developer.
- In the AWS console, switch to the region where your IAM Identity Center is configured.
- Go to IAM Identity Center → Settings.
- Open Identity source.
- Copy the Identity store ID.
- Paste it into Identity Store ID in LinearB.
d-. In multi-account
AWS organizations, IAM Identity Center may be configured in a different AWS
account from the IAM role or S3 bucket.
S3 Bucket Region
In S3 → Buckets, locate the reporting bucket and copy its AWS region into S3 Bucket Region.
Identity Center Region
Enter the AWS region where the IAM Identity Center used by Amazon Q Developer is enabled.
After entering all five values, click Continue. LinearB generates the permissions and trust policies required for the IAM role.
Apply the Generated AWS Policies
LinearB generates two policies. Apply each policy to the IAM role in the location specified below.
Apply the Permissions Policy
The Permissions Policy grants read-only access to the required Amazon Q Developer reporting and Identity Store resources.
- In LinearB, expand Permissions Policy.
- Copy the generated policy.
- In AWS, go to IAM → Roles.
- Open the
LinearBrole you created. - Open the Permissions tab.
- Select Add permissions → Create inline policy.
- Select JSON.
- Replace the existing JSON with the policy copied from LinearB.
- Save the inline policy.
Apply the Trust Policy
The Trust Policy allows the LinearB AWS account to assume the role and adds the External ID generated for this integration.
- In LinearB, expand Trust Policy.
- Copy the generated policy.
- In AWS, open the same IAM role.
- Open the Trust relationships tab.
- Click Edit trust policy.
- Replace the existing trust policy with the policy copied from LinearB.
- Save the trust policy.
Connect Amazon Q Developer
- Return to the Amazon Q Developer connection wizard in LinearB.
- Complete the remaining wizard steps and click Add Integration.
- LinearB validates the IAM role, S3 access, Identity Store access, and configured regions.
When validation succeeds, AWS — Amazon Q Developer appears in the Connected list.
Verify the Connection
- Open Settings → Company Settings → AI Tools → Integrations.
- Select Connected.
- Select AWS — Amazon Q Developer.
- Confirm that the integration status is Connected.
- Confirm that the displayed AWS settings match the reporting environment.
- Allow time for Amazon Q reports to be generated and processed.
- Open AI Analytics and confirm that Amazon Q data appears.
Edit the Amazon Q Developer Integration
Use Edit mode to update the AWS resources and regions used by the integration.
The following fields can be edited:
- IAM Role ARN
- Usage Data S3 Path
- Identity Store ID
- S3 Bucket Region
- Identity Center Region
- Open Settings → Company Settings → AI Tools → Integrations.
- Select Connected.
- Select AWS — Amazon Q Developer.
- Under Main Settings, click Edit.
- Update the required AWS settings.
- Click Save changes to apply the update or Cancel to discard it.
Apply the updated Trust Policy
- After saving the edit, expand Trust Policy.
- Copy the newly generated policy.
- Open the integration’s IAM role in AWS.
- Replace the existing Trust Policy with the newly generated policy.
- Save the role in AWS.
- Return to LinearB and verify the integration.
What happens to historical data?
Editing the integration does not delete previously collected Amazon Q metrics.
- Saving an edit triggers a new collection.
- LinearB recollects up to 90 days of recent Amazon Q data.
- Recollected records are updated in place and are not counted twice.
- Data older than the recollection window remains unchanged.
Disconnect or Reconnect
Disconnecting Amazon Q Developer stops new report collection and moves the integration to the Disconnected list. Previously collected data is preserved.
Disconnect the integration
- Open Settings → Company Settings → AI Tools → Integrations.
- Select Connected.
- Select AWS — Amazon Q Developer.
- Click Disconnect.
- Confirm the action.
Reconnect the integration
- Open Settings → Company Settings → AI Tools → Integrations.
- Select Disconnected.
- Select AWS — Amazon Q Developer.
- Click Reconnect.
- Review the saved AWS configuration.
- Complete validation to restore the integration.
LinearB validates the saved IAM role and AWS resources before restoring the integration.
Troubleshooting
Invalid IAM Role ARN
Verify that the complete ARN was copied from AWS. It should use this format:
arn:aws:iam::<account-id>:role/<role-name>
Invalid S3 URI
Verify that the path uses a valid S3 URI and contains the correct bucket and prefix:
s3://<bucket-name>/<report-prefix>/
Could Not Assume the IAM Role
- Confirm that the Trust Policy allows the LinearB AWS account as a principal.
-
Verify that
sts:ExternalIdexactly matches the current External ID shown in LinearB. - Confirm that the IAM Role ARN is correct.
- Verify that the Trust Policy was applied to the intended role.
- If the integration was edited, confirm that the newly generated Trust Policy was applied in AWS.
IAM Role Not Found
Confirm that the role exists in the AWS account identified by the ARN and that the complete ARN was entered in LinearB.
Temporary AWS Error
AWS STS throttling or temporary service unavailability can prevent validation. Wait a few minutes and try again.
S3 Bucket Not Found
- Confirm that the bucket name is correct.
- Verify that the configured S3 region matches the bucket’s actual region.
- Confirm that the bucket exists in the expected AWS account.
No Permission to List the S3 Bucket
Confirm that the IAM role permits s3:ListBucket for the
configured bucket and prefix.
No Permission to Read S3 Objects
Confirm that the IAM role permits s3:GetObject for the Amazon Q
report objects under the configured prefix.
Incorrect S3 Region
Update the configured S3 region so that it matches the bucket’s actual region.
IAM Identity Center Not Found
- Verify the Identity Store ID.
- Confirm the IAM Identity Center home region.
- Remember that the Identity Center and S3 bucket can use different regions.
Access Denied to Identity Store
Confirm that the IAM role has the required read-only Identity Store permissions, including access to retrieve and describe users.
No Amazon Q Data Appears
- Confirm that Amazon Q Developer user activity reports are enabled.
- Verify that reports exist under the configured S3 path.
- Confirm that the S3 path matches the Amazon Q report location.
- Allow time for the daily report and LinearB processing cycle.
- Verify that users can be resolved through the configured Identity Store.
- Confirm that the integration appears under Connected without an error indicator.
Known Limitations
- Data availability depends on the Amazon Q Developer reports present in the configured S3 path.
- Amazon Q reporting is updated daily, not in real time.
- Available metrics depend on the data returned through the AWS reports.
- Model, token, and estimated-consumption data is not currently available.
- Saving any edit regenerates the External ID and requires an updated IAM Trust Policy.
Related Articles
How did we do?
Choose a GitHub Copilot connection
Connect Claude Code using OpenTelemetry