Skip to content
New issue

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

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

Already on GitHub? # to your account

feat: add challenges to payout model #281

Merged
merged 1 commit into from
Feb 3, 2025

Conversation

tessstoddard
Copy link
Contributor

@tessstoddard tessstoddard commented Jan 31, 2025

Summary of Changes

Adds challenges to payout model and update model to use lombok getter/setters. And returns a 202 if challenges are present in the create payout response

Fixes # (issue)

Public API Additions/Changes

Adds challenges to payouts https://developer.mx.com/drafts/mdx/payout/#payouts-create-a-payout

Downstream Consumer Impact

This shouldn't have any impact since it's just adding new functionality.

How Has This Been Tested?

I pulled in these changes locally and ran the e2e tests and they all passed. I also verified that if the response has challenges that a 202 is returned

POST http://localhost:3015/globalcu/users/U-00ujqk7rkv4L6FFWK1d7/payouts

HTTP/1.1 202 
Content-Type: application/vnd.mx.mdx.v6+json;charset=UTF-8
Transfer-Encoding: chunked
Date: Fri, 31 Jan 2025 21:47:47 GMT

{
  "payout": {
    "challenges": [
      {
        "id": "an-id",
        "user_id": "U-00ujqk7rkv4L6FFWK1d7"
      }
    ],
    "user_id": "U-00ujqk7rkv4L6FFWK1d7"
  }
}

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my code
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works


@Data
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lombok makes java POJOs so much cleaner!

@tessstoddard tessstoddard merged commit 18c78dd into master Feb 3, 2025
4 checks passed
@tessstoddard tessstoddard deleted the tess/create_payout_challenges branch February 3, 2025 18:24
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants