Skip to content

Commit

Permalink
Merge pull request #307 from recurly/v3-v2019-10-10-1684788284
Browse files Browse the repository at this point in the history
Generated Latest Changes for v2019-10-10 (gateway_attributes on PaymentMethod)
  • Loading branch information
gilv93 authored May 22, 2023
2 parents d688c0e + 978e934 commit ef37433
Show file tree
Hide file tree
Showing 6 changed files with 77 additions and 2 deletions.
24 changes: 24 additions & 0 deletions lib/recurly.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -351,6 +351,10 @@ export declare class PaymentMethod {
* An identifier for a specific payment gateway.
*/
gatewayCode?: string | null;
/**
* Gateway specific attributes associated with this PaymentMethod
*/
gatewayAttributes?: GatewayAttributes | null;
/**
* Billing Agreement identifier. Only present for Amazon or Paypal payment methods.
*/
Expand All @@ -374,6 +378,14 @@ export declare class PaymentMethod {

}

export declare class GatewayAttributes {
/**
* Used by Adyen gateways. The Shopper Reference value used when the external token was created.
*/
accountReference?: string | null;

}

export declare class FraudInfo {
/**
* Kount score
Expand Down Expand Up @@ -3225,6 +3237,10 @@ export interface BillingInfoCreate {
* An identifier for a specific payment gateway. Must be used in conjunction with `gateway_token`.
*/
gatewayCode?: string | null;
/**
* Additional attributes to send to the gateway.
*/
gatewayAttributes?: GatewayAttributes | null;
/**
* Amazon billing agreement ID
*/
Expand Down Expand Up @@ -3292,6 +3308,14 @@ export interface BillingInfoCreate {

}

export interface GatewayAttributes {
/**
* Used by Adyen gateways. The Shopper Reference value used when the external token was created. Must be used in conjunction with gateway_token and gateway_code.
*/
accountReference?: string | null;

}

export interface CustomField {
/**
* Fields must be created in the UI before values can be assigned to them.
Expand Down
25 changes: 25 additions & 0 deletions lib/recurly/resources/GatewayAttributes.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
/* istanbul ignore file */
/**
* This file is automatically created by Recurly's OpenAPI generation process
* and thus any edits you make by hand will be lost. If you wish to make a
* change to this file, please create a Github issue explaining the changes you
* need and we will usher them to the appropriate places.
*/
'use strict'

const Resource = require('../Resource')

/**
* GatewayAttributes
* @typedef {Object} GatewayAttributes
* @prop {string} accountReference - Used by Adyen gateways. The Shopper Reference value used when the external token was created.
*/
class GatewayAttributes extends Resource {
static getSchema () {
return {
accountReference: String
}
}
}

module.exports = GatewayAttributes
2 changes: 2 additions & 0 deletions lib/recurly/resources/PaymentMethod.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ const Resource = require('../Resource')
* @prop {number} expMonth - Expiration month.
* @prop {number} expYear - Expiration year.
* @prop {string} firstSix - Credit card number's first six digits.
* @prop {GatewayAttributes} gatewayAttributes - Gateway specific attributes associated with this PaymentMethod
* @prop {string} gatewayCode - An identifier for a specific payment gateway.
* @prop {string} gatewayToken - A token used in place of a credit card in order to perform transactions.
* @prop {string} lastFour - Credit card number's last four digits. Will refer to bank account if payment method is ACH.
Expand All @@ -38,6 +39,7 @@ class PaymentMethod extends Resource {
expMonth: Number,
expYear: Number,
firstSix: String,
gatewayAttributes: 'GatewayAttributes',
gatewayCode: String,
gatewayToken: String,
lastFour: String,
Expand Down
1 change: 1 addition & 0 deletions lib/recurly/resources/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ module.exports.Account = require('./Account')
module.exports.ShippingAddress = require('./ShippingAddress')
module.exports.BillingInfo = require('./BillingInfo')
module.exports.PaymentMethod = require('./PaymentMethod')
module.exports.GatewayAttributes = require('./GatewayAttributes')
module.exports.FraudInfo = require('./FraudInfo')
module.exports.BillingInfoUpdatedBy = require('./BillingInfoUpdatedBy')
module.exports.CustomField = require('./CustomField')
Expand Down
23 changes: 23 additions & 0 deletions openapi/api.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16645,6 +16645,17 @@ components:
title: An identifier for a specific payment gateway. Must be used in conjunction
with `gateway_token`.
maxLength: 12
gateway_attributes:
type: object
description: Additional attributes to send to the gateway.
x-class-name: GatewayAttributes
properties:
account_reference:
type: string
description: Used by Adyen gateways. The Shopper Reference value used
when the external token was created. Must be used in conjunction with
gateway_token and gateway_code.
maxLength: 264
amazon_billing_agreement_id:
type: string
title: Amazon billing agreement ID
Expand Down Expand Up @@ -21470,6 +21481,7 @@ components:
- force_collect
- refunded_externally
- chargeback
- external_recovery
currency:
type: string
title: Currency
Expand Down Expand Up @@ -22185,6 +22197,7 @@ components:
object:
type: string
enum:
- bacs
- credit_card
- paypal
- amazon
Expand Down Expand Up @@ -22255,6 +22268,16 @@ components:
type: string
description: An identifier for a specific payment gateway.
maxLength: 13
gateway_attributes:
type: object
description: Gateway specific attributes associated with this PaymentMethod
x-class-name: GatewayAttributes
properties:
account_reference:
type: string
description: Used by Adyen gateways. The Shopper Reference value used
when the external token was created.
maxLength: 264
billing_agreement_id:
type: string
description: Billing Agreement identifier. Only present for Amazon or Paypal
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit ef37433

Please sign in to comment.