[Haskell-cafe] [ANN] aws-arn-0.1.0.0 - Library and optics for munging Amazon Resource Names (ARNs)
jack.kelly at bellroy.com
Wed Apr 7 00:36:41 UTC 2021
I have just pushed an initial release of aws-arn to Hackage.
This library provides a type representing Amazon Resource Names
(ARNs), and parsing/unparsing functions for them. The provided
optics make it very convenient to rewrite parts of ARNs.
An example, from the documentation: API Gateway Lambda Authorizers are
given the ARN of the requested endpoint and method, and are expected
to respond with an IAM Policy Document. It is sometimes useful to
manipulate the given ARN when describing which resources to authorize:
-- Returns "arn:aws:execute-api:us-east-1:123456789012:my-spiffy-api/stage/*"
over (_ARN . arnResource . slashes) (\parts -> take 2 parts ++
The code is available on GitHub; bug reports and pull requests are
welcome. There is some additional support for parsing specific
resource types -- PRs to support more resource types are especially
More information about the Haskell-Cafe