Skip to content

Feature request: JMESPath powertools functions #2207

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
1 of 2 tasks
dreamorosi opened this issue Mar 12, 2024 · 2 comments · Fixed by #2264
Closed
1 of 2 tasks

Feature request: JMESPath powertools functions #2207

dreamorosi opened this issue Mar 12, 2024 · 2 comments · Fixed by #2264
Assignees
Labels
completed This item is complete and has been merged/shipped feature-request This item refers to a feature request for an existing or new utility jmespath This item relates to the JMESPath Utility

Comments

@dreamorosi
Copy link
Contributor

Use case

As an added value for the Powertools JMESPath utility we will add some custom functions that can be used in JMESPath expression that are especially useful in the context of AWS Lambda.

The JMESPath built-in functions support number (i.e. avg, min, ceil, etc.), string (starts_with, contains, etc.), object (keys, max_by, etc.), and list (sort, values, etc.) operations, however when working with Lambda customers often receive payloads that are encoded.

By adding custom functions that decode part of the payload using common encodings, customers will be able to use JMESPath expressions on the entire payload.

Solution/User Experience

We will start with supporting three types of custom functions as they cover most of the AWS events:

  • powertools_json
  • powertools_base64
  • powertools_base64_gzip

Customers should also be able to extend the functionality of the utility and define their custom functions easily.

All types, classes, and functions should be documented and exposed to customers via API docs.

Alternative solutions

No response

Acknowledgment

Future readers

Please react with 👍 and your use case to help us understand customer demand.

@dreamorosi dreamorosi added feature-request This item refers to a feature request for an existing or new utility confirmed The scope is clear, ready for implementation jmespath This item relates to the JMESPath Utility labels Mar 12, 2024
@dreamorosi dreamorosi self-assigned this Mar 12, 2024
@dreamorosi dreamorosi moved this from Triage to Backlog in Powertools for AWS Lambda (TypeScript) Mar 12, 2024
@dreamorosi dreamorosi moved this from Backlog to Working on it in Powertools for AWS Lambda (TypeScript) Mar 21, 2024
@dreamorosi dreamorosi linked a pull request Mar 21, 2024 that will close this issue
9 tasks
@dreamorosi dreamorosi moved this from Working on it to Pending review in Powertools for AWS Lambda (TypeScript) Mar 21, 2024
@github-project-automation github-project-automation bot moved this from Pending review to Coming soon in Powertools for AWS Lambda (TypeScript) Mar 24, 2024
Copy link
Contributor

⚠️ COMMENT VISIBILITY WARNING ⚠️

This issue is now closed. Please be mindful that future comments are hard for our team to see.

If you need more assistance, please either tag a team member or open a new issue that references this one.

If you wish to keep having a conversation with other community members under this issue feel free to do so.

@github-actions github-actions bot added pending-release This item has been merged and will be released soon and removed confirmed The scope is clear, ready for implementation labels Mar 24, 2024
Copy link
Contributor

This is now released under v2.0.4 version!

@github-actions github-actions bot added completed This item is complete and has been merged/shipped and removed pending-release This item has been merged and will be released soon labels Apr 10, 2024
@dreamorosi dreamorosi moved this from Coming soon to Shipped in Powertools for AWS Lambda (TypeScript) Apr 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
completed This item is complete and has been merged/shipped feature-request This item refers to a feature request for an existing or new utility jmespath This item relates to the JMESPath Utility
Projects
Development

Successfully merging a pull request may close this issue.

1 participant