Skip to content

Commit 8007b06

Browse files
committed
Merge branch 'release/1.15.0' into beta
2 parents 45939a1 + 9cc27d0 commit 8007b06

16 files changed

+168
-28
lines changed

src/backend/Graph/cart.d.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import type { CreateSession } from './create_session';
44
import type { CustomFields } from './custom_fields';
55
import type { Customer } from './customer';
66
import type { Discounts } from './discounts';
7+
import type { GiftCardCodeLogs } from './gift_card_code_logs';
78
import type { Graph } from '../../core';
89
import type { Items } from './items';
910
import type { Store } from './store';
@@ -33,6 +34,8 @@ export interface Cart extends Graph {
3334
'fx:create_session': CreateSession;
3435
/** Coupon codes applied to the items in this cart. */
3536
'fx:applied_coupon_codes': AppliedCouponCodes;
37+
/** Gift card codes applied to the items in this cart. */
38+
'fx:applied_gift_card_codes': GiftCardCodeLogs;
3639
};
3740

3841
props: {
@@ -134,6 +137,8 @@ export interface Cart extends Graph {
134137
};
135138

136139
zooms: {
140+
applied_coupon_codes?: AppliedCouponCodes;
141+
gift_card_code_logs?: GiftCardCodeLogs; // the zoom name is `applied_gift_card_codes`, but the resource is `gift_card_code_logs` so we use that here due to the limitations of the SDK types
137142
custom_fields?: CustomFields;
138143
attributes: Attributes;
139144
discounts?: Discounts;
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
import type { Graph } from '../../core';
2+
3+
export interface ChargePastDue extends Graph {
4+
curie: 'fx:charge_past_due';
5+
}

src/backend/Graph/countries.d.ts

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -27,21 +27,21 @@ export interface Countries extends Graph {
2727
alternate_values: string[];
2828
/** This value determines which countries will show up first in our find-as-you-type system. */
2929
boost: number;
30-
/** If `include_regions` is passed in, this will be replaced with regions, an array of region information for this country. Boolean otherwise. */
31-
has_regions:
32-
| boolean
33-
| {
34-
/** The default name for this region. */
35-
n: string;
36-
/** The official region code. */
37-
c: string;
38-
/** Array of alternative names for this region. */
39-
alt: string[];
40-
/** This value determines which regions will show up first in our find-as-you-type system. */
41-
boost: number;
42-
/** If this region is currently recognized. */
43-
active: boolean;
44-
}[];
30+
/** Whether this country has known regions on file in our system. If `?include_regions=true` is passed in, this property will be omitted. */
31+
has_regions?: boolean;
32+
/** Known regions for this country if Foxy is aware of them. If `?include_regions=true` is not passed in, this property will be omitted. */
33+
regions?: {
34+
/** The default name for this region. */
35+
n: string;
36+
/** The official region code. */
37+
c: string;
38+
/** Array of alternative names for this region. */
39+
alt: string[];
40+
/** This value determines which regions will show up first in our find-as-you-type system. */
41+
boost: number;
42+
/** If this region is currently recognized. */
43+
active: boolean;
44+
}[];
4545
/** Whether this country requires regions for shipping or not. */
4646
regions_required: boolean;
4747
/** What type of region this is such as state, province, etc. */

src/backend/Graph/hosted_payment_gateways_helper.d.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,12 @@ export interface HostedPaymentGatewaysHelper extends Graph {
3737
third_party_key_description: string;
3838
/** Marks hosted payment gateways that are no longer supported. */
3939
is_deprecated: boolean;
40+
/** Whether or not this hosted gateway supports card verification. */
41+
supports_card_verification: boolean;
42+
/** Default card verification mode if this gateway supports it. */
43+
card_verification: 'disabled' | 'enabled_automatically' | 'enabled_override';
44+
/** Default configuration for card verification amounts. This is a serialized JSON string that contains the amounts for each card type. Example: `{"verification_amounts": {"visa": 1, "mastercard": 1, "american_express": 1, "discover": 1, "default": 1}}`. */
45+
card_verification_config: string;
4046
/** If this hosted gateway requires additional information, this will contain details about the data which needs to be collected to configure this hosted gateway. */
4147
additional_fields: null | {
4248
blocks: {

src/backend/Graph/payment_gateway.d.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,14 @@ export interface PaymentGateway extends Graph {
4040
test_account_key: string;
4141
/** Your test payment gateway third party key. To view the specific description of this field for the given payment gateway, see {@link https://api-sandbox.foxycart.com/hal-browser/browser.html#https://api-sandbox.foxycart.com/property_helpers/payment_gateways payment_gateways} property helper `third_party_key_description` field. */
4242
test_third_party_key: string;
43+
/** Live card verification mode if this gateway supports it. */
44+
card_verification: 'disabled' | 'enabled_automatically' | 'enabled_override';
45+
/** Live configuration for card verification amounts. This is a serialized JSON string that contains the amounts for each card type. Example: `{"verification_amounts": {"visa": 1, "mastercard": 1, "american_express": 1, "discover": 1, "default": 1}}`. */
46+
card_verification_config: string;
47+
/** Test card verification mode if this gateway supports it. */
48+
test_card_verification: 'disabled' | 'enabled_automatically' | 'enabled_override';
49+
/** Test configuration for card verification amounts. This is a serialized JSON string that contains the amounts for each card type. Example: `{"verification_amounts": {"visa": 1, "mastercard": 1, "american_express": 1, "discover": 1, "default": 1}}`. */
50+
test_card_verification_config: string;
4351
/** The date this resource was created. */
4452
date_created: string | null;
4553
/** The date this resource was last modified. */

src/backend/Graph/payment_gateways_helper.d.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,12 @@ export interface PaymentGatewaysHelper extends Graph {
3737
third_party_key_description: string;
3838
/** Marks payment gateways that are no longer supported. */
3939
is_deprecated: boolean;
40+
/** Whether or not this gateway supports card verification. */
41+
supports_card_verification: boolean;
42+
/** Default card verification mode if this gateway supports it. */
43+
card_verification: 'disabled' | 'enabled_automatically' | 'enabled_override';
44+
/** Default configuration for card verification amounts. This is a serialized JSON string that contains the amounts for each card type. Example: `{"verification_amounts": {"visa": 1, "mastercard": 1, "american_express": 1, "discover": 1, "default": 1}}`. */
45+
card_verification_config: string;
4046
/** If this gateway requires additional information, this will contain details about the data which needs to be collected to configure this gateway. */
4147
additional_fields: null | {
4248
blocks: {

src/backend/Graph/store.d.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@ import type { PaymentMethodSets } from './payment_method_sets';
1818
import type { ProcessSubscriptionWebhook } from './process_subscription_webhook';
1919
import type { ReceiptTemplates } from './receipt_templates';
2020
import type { Reports } from './reports';
21+
import type { StoreShippingMethods } from './store_shipping_methods';
22+
import type { StoreTransactionFolders } from './store_transaction_folders';
2123
import type { StoreVersion } from './store_version';
2224
import type { SubscriptionSettings } from './subscription_settings';
2325
import type { Subscriptions } from './subscriptions';
@@ -28,7 +30,6 @@ import type { UserAccesses } from './user_accesses';
2830
import type { UserInvitations } from './user_invitations';
2931
import type { Users } from './users';
3032
import type { Webhooks } from './webhooks';
31-
import type { StoreShippingMethods } from './store_shipping_methods';
3233

3334
export interface Store extends Graph {
3435
curie: 'fx:store';
@@ -84,6 +85,8 @@ export interface Store extends Graph {
8485
'fx:checkout_templates': CheckoutTemplates;
8586
/** List of payment method sets configured for this store. */
8687
'fx:payment_method_sets': PaymentMethodSets;
88+
/** List of transaction folders for this store. */
89+
'fx:transaction_folders': StoreTransactionFolders;
8790
/** Subscription settings for this store. */
8891
'fx:subscription_settings': SubscriptionSettings;
8992
/** List of cart include templates available in this store. */
@@ -129,6 +132,8 @@ export interface Store extends Graph {
129132
use_email_dns: boolean;
130133
/** If you'd like to configure your own SMTP server for sending transaction receipt emails, you can do so here. The JSON supports the following fields: `username`,`password`,`host`,`port`,`security`. The security value can be blank, `ssl`, or `tls` */
131134
smtp_config: string;
135+
/** Set to true if you would like to send HTML formatted emails. */
136+
send_html_email: boolean;
132137
/** The postal code of your store. This will be used for calculating shipping costs if you sell shippable items. */
133138
postal_code: string;
134139
/** The two character code for states in the United States. Other countries may call this a province. When a two character code isn't available, use the full region name. This will be used for calculating shipping costs if you sell shippable items. */
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
import type { Graph } from '../../core';
2+
import type { Store } from './store';
3+
4+
export interface StoreTransactionFolder extends Graph {
5+
curie: 'fx:folder';
6+
7+
links: {
8+
/** This resource. */
9+
'self': StoreTransactionFolder;
10+
/** Related store resource. */
11+
'fx:store': Store;
12+
};
13+
14+
props: {
15+
/** Name of the folder. Required. */
16+
name: string;
17+
/** When set to `1`, new transactions will be automatically assigned to this folder. Only one folder can be default at a time. If you update one folder to be the default one we will mark others as non default. Optional. Default: `0`.*/
18+
is_default: 0 | 1;
19+
/** Optional display order for this folder. Our admin dashboard will sort folders by this value (ascending). Default: `0`. */
20+
sort_order: number;
21+
/** Optional display color for this folder. API will accept any value, however our admin dashboard will recognize only the following: `red`, `red_pale`, `green`, `green_pale`, `blue`, `blue_pale`, `orange`, `orange_pale`, `violet`, `violet_pale`. Default: `null`. */
22+
color: string | null;
23+
/** The date and time this folder was created in ISO 8601 format. */
24+
date_created: string;
25+
/** The date and time this folder was last modified in ISO 8601 format. */
26+
date_modified: string;
27+
};
28+
}
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
import type { CollectionGraphLinks, CollectionGraphProps } from '../../core/defaults';
2+
import type { Graph } from '../../core';
3+
import type { StoreTransactionFolder } from './store_transaction_folder';
4+
5+
export interface StoreTransactionFolders extends Graph {
6+
curie: 'fx:transaction_folders';
7+
links: CollectionGraphLinks<StoreTransactionFolders>;
8+
props: CollectionGraphProps;
9+
child: StoreTransactionFolder;
10+
}

src/backend/Graph/subscription.d.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import type { Attributes } from './attributes';
2+
import type { ChargePastDue } from './charge_past_due';
23
import type { Customer } from './customer';
34
import type { Graph } from '../../core';
45
import type { LastTransaction } from './last_transaction';
@@ -31,6 +32,8 @@ export interface Subscription extends Graph {
3132
'fx:sub_token_url': SubTokenUrl;
3233
/** URL of the page where the customer can modify this subscription. This link is available only when configured in subscription settings. */
3334
'fx:sub_modification_url': SubModificationUrl;
35+
/** POST to this endpoint to charge any past due payments for this subscription. Not present when there's no past due amount to charge. */
36+
'fx:charge_past_due': ChargePastDue;
3437
};
3538

3639
props: {

0 commit comments

Comments
 (0)