Skip to content

Commit

Permalink
Merge branch 'main' into tests
Browse files Browse the repository at this point in the history
# Conflicts:
#	src/errors/customerErrorResponseError.ts
  • Loading branch information
patryk-grudzien-keen committed Nov 7, 2023
2 parents 182021f + a0a048c commit b5751e4
Show file tree
Hide file tree
Showing 6 changed files with 48 additions and 46 deletions.
68 changes: 34 additions & 34 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -332,7 +332,7 @@ npm install

## Initialize the API Client

**_Note:_** Documentation for the client can be found [here.](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/client.md)
**_Note:_** Documentation for the client can be found [here.](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/client.md)

The following parameters are configurable for the API Client:

Expand Down Expand Up @@ -396,40 +396,40 @@ This API uses `Basic Authentication`.

## List of APIs

* [API Exports](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/api-exports.md)
* [Advance Invoice](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/advance-invoice.md)
* [Billing Portal](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/billing-portal.md)
* [Custom Fields](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/custom-fields.md)
* [Events-Based Billing Segments](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/events-based-billing-segments.md)
* [Payment Profiles](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/payment-profiles.md)
* [Product Families](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/product-families.md)
* [Product Price Points](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/product-price-points.md)
* [Proforma Invoices](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/proforma-invoices.md)
* [Reason Codes](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/reason-codes.md)
* [Referral Codes](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/referral-codes.md)
* [Sales Commissions](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/sales-commissions.md)
* [Subscription Components](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/subscription-components.md)
* [Subscription Groups](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/subscription-groups.md)
* [Subscription Group Invoice Account](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/subscription-group-invoice-account.md)
* [Subscription Group Status](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/subscription-group-status.md)
* [Subscription Invoice Account](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/subscription-invoice-account.md)
* [Subscription Notes](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/subscription-notes.md)
* [Subscription Products](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/subscription-products.md)
* [Subscription Status](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/subscription-status.md)
* [Coupons](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/coupons.md)
* [Components](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/components.md)
* [Customers](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/customers.md)
* [Events](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/events.md)
* [Insights](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/insights.md)
* [Invoices](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/invoices.md)
* [Offers](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/offers.md)
* [Products](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/products.md)
* [Sites](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/sites.md)
* [Subscriptions](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/subscriptions.md)
* [Webhooks](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/controllers/webhooks.md)
* [API Exports](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/api-exports.md)
* [Advance Invoice](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/advance-invoice.md)
* [Billing Portal](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/billing-portal.md)
* [Custom Fields](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/custom-fields.md)
* [Events-Based Billing Segments](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/events-based-billing-segments.md)
* [Payment Profiles](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/payment-profiles.md)
* [Product Families](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/product-families.md)
* [Product Price Points](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/product-price-points.md)
* [Proforma Invoices](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/proforma-invoices.md)
* [Reason Codes](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/reason-codes.md)
* [Referral Codes](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/referral-codes.md)
* [Sales Commissions](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/sales-commissions.md)
* [Subscription Components](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/subscription-components.md)
* [Subscription Groups](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/subscription-groups.md)
* [Subscription Group Invoice Account](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/subscription-group-invoice-account.md)
* [Subscription Group Status](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/subscription-group-status.md)
* [Subscription Invoice Account](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/subscription-invoice-account.md)
* [Subscription Notes](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/subscription-notes.md)
* [Subscription Products](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/subscription-products.md)
* [Subscription Status](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/subscription-status.md)
* [Coupons](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/coupons.md)
* [Components](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/components.md)
* [Customers](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/customers.md)
* [Events](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/events.md)
* [Insights](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/insights.md)
* [Invoices](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/invoices.md)
* [Offers](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/offers.md)
* [Products](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/products.md)
* [Sites](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/sites.md)
* [Subscriptions](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/subscriptions.md)
* [Webhooks](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/controllers/webhooks.md)

## Classes Documentation

* [ApiResponse](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/api-response.md)
* [ApiError](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.5/doc/api-error.md)
* [ApiResponse](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/api-response.md)
* [ApiError](https://www.github.com/maxio-com/ab-typescript-sdk/tree/0.0.6/doc/api-error.md)

4 changes: 2 additions & 2 deletions doc/models/subscription-group-inlined.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
| `uid` | `string \| undefined` | Optional | The UID for the group |
| `scheme` | `string \| undefined` | Optional | Whether the group is configured to rely on a primary subscription for billing. At this time, it will always be 1. |
| `primarySubscriptionId` | `string \| undefined` | Optional | The subscription ID of the primary within the group. Applicable to scheme 1. |
| `primary` | `string \| undefined` | Optional | A boolean indicating whether the subscription is the primary in the group. Applicable to scheme 1. |
| `primary` | `boolean \| undefined` | Optional | A boolean indicating whether the subscription is the primary in the group. Applicable to scheme 1. |

## Example (as JSON)

Expand All @@ -21,7 +21,7 @@
"uid": "uid2",
"scheme": "scheme2",
"primary_subscription_id": "primary_subscription_id8",
"primary": "primary8"
"primary": false
}
```

6 changes: 3 additions & 3 deletions src/controllers/customFieldsController.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
*/

import { ApiError } from '@apimatic/core';
import { ApiResponse, commaPrefix, RequestOptions } from '../core';
import { ApiResponse, plainPrefix, RequestOptions } from '../core';
import { BasicDateField, basicDateFieldSchema } from '../models/basicDateField';
import {
ListMetadataDirection,
Expand Down Expand Up @@ -397,7 +397,7 @@ export class CustomFieldsController extends BaseController {
names: [names, optional(array(string()))],
});
req.query('name', mapped.name);
req.query('names[]', mapped.names, commaPrefix);
req.query('names[]', mapped.names, plainPrefix);
req.appendTemplatePath`/${mapped.resourceType}/${mapped.resourceId}/metadata.json`;
req.throwOn(404, ApiError, 'Not Found');
return req.call(requestOptions);
Expand Down Expand Up @@ -492,7 +492,7 @@ export class CustomFieldsController extends BaseController {
req.query('start_datetime', mapped.startDatetime);
req.query('end_datetime', mapped.endDatetime);
req.query('with_deleted', mapped.withDeleted);
req.query('resource_ids[]', mapped.resourceIds, commaPrefix);
req.query('resource_ids[]', mapped.resourceIds, plainPrefix);
req.query('direction', mapped.direction);
req.appendTemplatePath`/${mapped.resourceType}/metadata.json`;
return req.callAsJson(paginatedMetadataSchema, requestOptions);
Expand Down
6 changes: 3 additions & 3 deletions src/controllers/subscriptionsController.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
*/

import { ApiError } from '@apimatic/core';
import { ApiResponse, commaPrefix, RequestOptions } from '../core';
import { ApiResponse, plainPrefix, RequestOptions } from '../core';
import { ErrorListResponseError } from '../errors/errorListResponseError';
import { NestedErrorResponseError } from '../errors/nestedErrorResponseError';
import {
Expand Down Expand Up @@ -1150,7 +1150,7 @@ export class SubscriptionsController extends BaseController {
subscriptionId: [subscriptionId, string()],
include: [include, optional(array(subscriptionIncludeSchema))],
});
req.query('include[]', mapped.include, commaPrefix);
req.query('include[]', mapped.include, plainPrefix);
req.appendTemplatePath`/subscriptions/${mapped.subscriptionId}.json`;
return req.callAsJson(subscriptionResponseSchema, requestOptions);
}
Expand Down Expand Up @@ -1263,7 +1263,7 @@ export class SubscriptionsController extends BaseController {
cascade: [cascade, optional(array(subscriptionPurgeTypeSchema))],
});
req.query('ack', mapped.ack);
req.query('cascade[]', mapped.cascade, commaPrefix);
req.query('cascade[]', mapped.cascade, plainPrefix);
req.appendTemplatePath`/subscriptions/${mapped.subscriptionId}/purge.json`;
req.throwOn(400, ApiError, 'Bad Request');
return req.call(requestOptions);
Expand Down
4 changes: 3 additions & 1 deletion src/errors/customerErrorResponseError.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@
*/

import { ApiError } from '../core';
import { CustomerErrorResponseErrors } from '../models/containers/customerErrorResponseErrors';
import {
CustomerErrorResponseErrors,
} from '../models/containers/customerErrorResponseErrors';

/**
* Creates an instance of CustomerErrorResponse
Expand Down
6 changes: 3 additions & 3 deletions src/models/subscriptionGroupInlined.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* This file was automatically generated for Maxio by APIMATIC v3.0 ( https://www.apimatic.io ).
*/

import { object, optional, Schema, string } from '../schema';
import { boolean, object, optional, Schema, string } from '../schema';

export interface SubscriptionGroupInlined {
/** The UID for the group */
Expand All @@ -14,14 +14,14 @@ export interface SubscriptionGroupInlined {
/** The subscription ID of the primary within the group. Applicable to scheme 1. */
primarySubscriptionId?: string;
/** A boolean indicating whether the subscription is the primary in the group. Applicable to scheme 1. */
primary?: string;
primary?: boolean;
}

export const subscriptionGroupInlinedSchema: Schema<SubscriptionGroupInlined> = object(
{
uid: ['uid', optional(string())],
scheme: ['scheme', optional(string())],
primarySubscriptionId: ['primary_subscription_id', optional(string())],
primary: ['primary', optional(string())],
primary: ['primary', optional(boolean())],
}
);

0 comments on commit b5751e4

Please sign in to comment.