Skip to content

feat(payouts): add organization_id to payouts#9938

Merged
Gnanasundari24 merged 2 commits intomainfrom
add_org_id_to_payouts
Oct 23, 2025
Merged

feat(payouts): add organization_id to payouts#9938
Gnanasundari24 merged 2 commits intomainfrom
add_org_id_to_payouts

Conversation

@Sakilmostak
Copy link
Contributor

@Sakilmostak Sakilmostak commented Oct 21, 2025

Type of Change

  • Bugfix
  • New feature
  • Enhancement
  • Refactoring
  • Dependency updates
  • Documentation
  • CI/CD

Description

add organization_id to payouts table for audit trail

Additional Changes

  • This PR modifies the API contract
  • This PR modifies the database schema
  • This PR modifies application configuration/environment variables

Motivation and Context

How did you test it?

Create an payout intent (confirm as false):

{
    "amount": 100,
    "currency": "GBP",
    "customer_id": "payout_customer",
    "email": "payout_customer@example.com",
    "name": "John Doe",
    "phone": "999999999",
    "phone_country_code": "+65",
    "description": "Its my first payout request",
    "billing": {
        "address": {
            "line1": "1467",
            "line2": "Harrison Street",
            "line3": "Harrison Street",
            "city": "San Fransico",
            "state": "NY",
            "zip": "94122",
            "country": "GB",
            "first_name": "John",
            "last_name": "Doe"  
        },
        "phone": {
            "number": "8056594427",
            "country_code": "+91"
        }
    },
    "entity_type": "Individual",
    "metadata": {
        "ref": "123"
    },
    "auto_fulfill": true,
    "confirm": false
}

Check in the database if organization_id is present against the payout entry

select organization_id from payouts where payout_id='{{id_picked_from_response}}';

Note: organization_id wont be present in payout's response since it is strictly used for analytics

Checklist

  • I formatted the code cargo +nightly fmt --all
  • I addressed lints thrown by cargo clippy
  • I reviewed the submitted code
  • I added unit tests for my changes where possible

@Sakilmostak Sakilmostak self-assigned this Oct 21, 2025
@Sakilmostak Sakilmostak requested review from a team as code owners October 21, 2025 08:43
@Sakilmostak Sakilmostak added A-core Area: Core flows C-feature Category: Feature request or enhancement Payouts Area: Payouts labels Oct 21, 2025
@semanticdiff-com
Copy link

semanticdiff-com bot commented Oct 21, 2025

@hyperswitch-bot hyperswitch-bot bot added the M-database-changes Metadata: This PR involves database schema changes label Oct 21, 2025
@Sakilmostak Sakilmostak linked an issue Oct 21, 2025 that may be closed by this pull request
@Gnanasundari24 Gnanasundari24 added this pull request to the merge queue Oct 23, 2025
Merged via the queue into main with commit 175d0f5 Oct 23, 2025
37 of 41 checks passed
@Gnanasundari24 Gnanasundari24 deleted the add_org_id_to_payouts branch October 23, 2025 08:01
drdholu pushed a commit to drdholu/hyperswitch that referenced this pull request Oct 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-core Area: Core flows C-feature Category: Feature request or enhancement M-database-changes Metadata: This PR involves database schema changes Payouts Area: Payouts

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEATURE]: [PAYOUTS] add organization_id to payouts table

4 participants