millions-planet-24262
06/11/2025, 8:51 AMaws.organizations.getOrganization
.
The problem I am facing that it seems to be ignoring the AWS Provider I am giving it and trying to perform a lookup with my current credentials, instead of assuming the ones provided in the provider.
The rough set-up is:
const managementAccountProvider = new aws.Provider('management-account-provider', {
assumeRole: { roleArn: managementAccountProviderRoleArn },
region: aws.Region.APSoutheast2,
});
const organization = aws.organizations.getOrganizationOutput({ provider: managementAccountProvider });
and I am getting the
* reading Organizations Organization: operation error Organizations: DescribeOrganization, https response error StatusCode: 400, RequestID: be2ef75b-81af-401a-bd98-f6db6e446222, AccessDeniedException: You don't have permissions to access this resource.
which is correct if using my current role, but if it would use the role assumed in the managementAccountProvider
, it will be fine, because that user has all the perms needed.
Any ideas what am I doing wrong?little-cartoon-10569
06/11/2025, 8:20 PMlittle-cartoon-10569
06/11/2025, 8:22 PMlittle-cartoon-10569
06/11/2025, 8:23 PMsourceIdentity
isn't a bad idea. It might help you track the problem down.millions-planet-24262
06/12/2025, 12:32 AMorganizations:DescribeOrganization
I had organization:DescribeOrganization
😐 I really wish we had constants for this and also that AWS actually validated things instead of blindly accepting them...