import * as Schema from "effect/Schema";
import { API } from "../client.js";
import * as T from "../traits.js";
// Input Schema
export const PostTestHelpersTreasuryOutboundPaymentsIdReturnInput = 
/*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    id: Schema.String.pipe(T.PathParam()),
    expand: Schema.optional(Schema.Array(Schema.String)),
    returned_details: Schema.optional(Schema.Struct({
        code: Schema.optional(Schema.Literals([
            "account_closed",
            "account_frozen",
            "bank_account_restricted",
            "bank_ownership_changed",
            "declined",
            "incorrect_account_holder_name",
            "invalid_account_number",
            "invalid_currency",
            "no_account",
            "other",
        ])),
    })),
}).pipe(T.Http({
    method: "POST",
    path: "/v1/test_helpers/treasury/outbound_payments/{id}/return",
    contentType: "form-urlencoded",
}));
// Output Schema
export const PostTestHelpersTreasuryOutboundPaymentsIdReturnOutput = 
/*@__PURE__*/ /*#__PURE__*/ Schema.Struct({
    amount: Schema.Number,
    cancelable: Schema.Boolean,
    created: Schema.Number,
    currency: Schema.String,
    customer: Schema.NullOr(Schema.String),
    description: Schema.NullOr(Schema.String),
    destination_payment_method: Schema.NullOr(Schema.String),
    destination_payment_method_details: Schema.Unknown,
    end_user_details: Schema.Unknown,
    expected_arrival_date: Schema.Number,
    financial_account: Schema.String,
    hosted_regulatory_receipt_url: Schema.NullOr(Schema.String),
    id: Schema.String,
    livemode: Schema.Boolean,
    metadata: Schema.Record(Schema.String, Schema.String),
    object: Schema.Literals(["treasury.outbound_payment"]),
    returned_details: Schema.Unknown,
    statement_descriptor: Schema.String,
    status: Schema.Literals([
        "canceled",
        "failed",
        "posted",
        "processing",
        "returned",
    ]),
    status_transitions: Schema.Struct({
        canceled_at: Schema.NullOr(Schema.Number),
        failed_at: Schema.NullOr(Schema.Number),
        posted_at: Schema.NullOr(Schema.Number),
        returned_at: Schema.NullOr(Schema.Number),
    }),
    tracking_details: Schema.Unknown,
    transaction: Schema.Unknown,
});
// The operation
/**
 * Test mode: Return an OutboundPayment
 *
 * <p>Transitions a test mode created OutboundPayment to the <code>returned</code> status. The OutboundPayment must already be in the <code>processing</code> state.</p>
 */
export const PostTestHelpersTreasuryOutboundPaymentsIdReturn = 
/*@__PURE__*/ /*#__PURE__*/ API.make(() => ({
    inputSchema: PostTestHelpersTreasuryOutboundPaymentsIdReturnInput,
    outputSchema: PostTestHelpersTreasuryOutboundPaymentsIdReturnOutput,
}));
//# sourceMappingURL=PostTestHelpersTreasuryOutboundPaymentsIdReturn.js.map