Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DE-618,DE-619] Fix interval units and date fields in subscription and product models #33

Merged
merged 6 commits into from
Nov 27, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
92 changes: 46 additions & 46 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -274,16 +274,16 @@ Install the SDK by adding the following dependency in your project's pom.xml fil
<dependency>
<groupId>com.maxio</groupId>
<artifactId>advanced-billing-sdk</artifactId>
<version>0.0.6</version>
<version>0.0.3</version>
</dependency>
```

You can also view the package at:
https://mvnrepository.com/artifact/com.maxio/advanced-billing-sdk/0.0.6
https://mvnrepository.com/artifact/com.maxio/advanced-billing-sdk/0.0.3

## Initialize the API Client

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

The following parameters are configurable for the API Client:

Expand All @@ -292,7 +292,7 @@ The following parameters are configurable for the API Client:
| `subdomain` | `String` | The subdomain for your Chargify site.<br>*Default*: `"subdomain"` |
| `domain` | `String` | The Chargify server domain.<br>*Default*: `"chargify.com"` |
| `environment` | Environment | The API environment. <br> **Default: `Environment.PRODUCTION`** |
| `httpClientConfig` | [`ReadonlyHttpClientConfiguration`](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.6/doc/http-client-configuration.md) | Http Client Configuration instance. |
| `httpClientConfig` | [`ReadonlyHttpClientConfiguration`](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.3/doc/http-client-configuration.md) | Http Client Configuration instance. |
| `basicAuthUserName` | `String` | The username to use with basic authentication |
| `basicAuthPassword` | `String` | The password to use with basic authentication |

Expand Down Expand Up @@ -326,49 +326,49 @@ This API uses `Basic Authentication`.

## List of APIs

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

## Classes Documentation

* [Utility Classes](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.6/doc/utility-classes.md)
* [HttpRequest](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.6/doc/http-request.md)
* [HttpResponse](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.6/doc/http-response.md)
* [HttpStringResponse](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.6/doc/http-string-response.md)
* [HttpContext](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.6/doc/http-context.md)
* [HttpBodyRequest](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.6/doc/http-body-request.md)
* [Headers](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.6/doc/headers.md)
* [ApiException](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.6/doc/api-exception.md)
* [Configuration Interface](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.6/doc/configuration-interface.md)
* [HttpClientConfiguration](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.6/doc/http-client-configuration.md)
* [HttpClientConfiguration.Builder](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.6/doc/http-client-configuration-builder.md)
* [Utility Classes](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.3/doc/utility-classes.md)
* [HttpRequest](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.3/doc/http-request.md)
* [HttpResponse](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.3/doc/http-response.md)
* [HttpStringResponse](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.3/doc/http-string-response.md)
* [HttpContext](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.3/doc/http-context.md)
* [HttpBodyRequest](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.3/doc/http-body-request.md)
* [Headers](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.3/doc/headers.md)
* [ApiException](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.3/doc/api-exception.md)
* [Configuration Interface](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.3/doc/configuration-interface.md)
* [HttpClientConfiguration](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.3/doc/http-client-configuration.md)
* [HttpClientConfiguration.Builder](https://www.github.com/maxio-com/ab-java-sdk/tree/0.0.3/doc/http-client-configuration-builder.md)

8 changes: 3 additions & 5 deletions doc/controllers/components.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,9 +78,7 @@ CreateComponentBody body = CreateComponentBody.fromCreateMeteredComponent(
new MeteredComponent.Builder(
"Text messages",
"text message",
MeteredComponentPricingScheme.fromPricingScheme(
PricingScheme.STAIRSTEP
)
PricingScheme.STAIRSTEP
)
.taxable(false)
.prices(Arrays.asList(
Expand Down Expand Up @@ -1475,8 +1473,8 @@ ListComponentsPricePointsResponse listAllComponentPricePoints(
| `perPage` | `Integer` | Query, Optional | This parameter indicates how many records to fetch in each request. Default value is 20. The maximum allowed values is 200; any per_page value over 200 will be changed to 200.<br>Use in query `per_page=200`.<br>**Default**: `20`<br>**Constraints**: `<= 200` |
| `filterStartDate` | `String` | Query, Optional | The start date (format YYYY-MM-DD) with which to filter the date_field. Returns price points with a timestamp at or after midnight (12:00:00 AM) in your site’s time zone on the date specified. |
| `filterStartDatetime` | `String` | Query, Optional | The start date and time (format YYYY-MM-DD HH:MM:SS) with which to filter the date_field. Returns price points with a timestamp at or after exact time provided in query. You can specify timezone in query - otherwise your site's time zone will be used. If provided, this parameter will be used instead of start_date. |
| `filterType` | [`PricePointType`](../../doc/models/price-point-type.md) | Query, Optional | Allows fetching price points with matching type. Use in query: `filter[type]=custom,catalog`. |
| `direction` | [`ListAllComponentPricePointsInputDirection`](../../doc/models/containers/list-all-component-price-points-input-direction.md) | Query, Optional | This is a container for one-of cases. |
| `filterType` | [`List<PricePointType>`](../../doc/models/price-point-type.md) | Query, Optional | Allows fetching price points with matching type. Use in query: `filter[type]=custom,catalog`. |
| `direction` | [`SortingDirection`](../../doc/models/sorting-direction.md) | Query, Optional | Controls the order in which results are returned.<br>Use in query `direction=asc`. |
| `filterIds` | `List<Integer>` | Query, Optional | Allows fetching price points with matching id based on provided values. Use in query: `filter[ids]=1,2,3`. |
| `filterArchivedAt` | [`IncludeNotNull`](../../doc/models/include-not-null.md) | Query, Optional | Allows fetching price points only if archived_at is present or not. Use in query: `filter[archived_at]=not_null`. |

Expand Down
8 changes: 2 additions & 6 deletions doc/controllers/coupons.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,9 +80,7 @@ CreateCouponBody body = CreateCouponBody.fromCreateOrUpdateCoupon(
.endDate("2012-08-29T12:00:00-04:00")
.productFamilyId("2")
.stackable("true")
.compoundingStrategy(CreateOrUpdatePercentageCouponCompoundingStrategy.fromCompoundingStrategy(
CompoundingStrategy.COMPOUND
))
.compoundingStrategy(CompoundingStrategy.COMPOUND)
.excludeMidPeriodAllocations(true)
.applyOnCancelAtEndOfPeriod(true)
.build()
Expand Down Expand Up @@ -419,9 +417,7 @@ UpdateCouponBody body = UpdateCouponBody.fromCreateOrUpdateCoupon(
.endDate("2012-08-29T12:00:00-04:00")
.productFamilyId("2")
.stackable("true")
.compoundingStrategy(CreateOrUpdatePercentageCouponCompoundingStrategy.fromCompoundingStrategy(
CompoundingStrategy.COMPOUND
))
.compoundingStrategy(CompoundingStrategy.COMPOUND)
.build()
))
.restrictedProducts(new LinkedHashMap<String, Boolean>() {{
Expand Down
4 changes: 2 additions & 2 deletions doc/controllers/custom-fields.md
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ ListMetafieldsResponse listMetafields(
| `name` | `String` | Query, Optional | filter by the name of the metafield |
| `page` | `Integer` | Query, Optional | Result records are organized in pages. By default, the first page of results is displayed. The page parameter specifies a page number of results to fetch. You can start navigating through the pages to consume the results. You do this by passing in a page parameter. Retrieve the next page by adding ?page=2 to the query string. If there are no results to return, then an empty result set will be returned.<br>Use in query `page=1`.<br>**Default**: `1`<br>**Constraints**: `>= 1` |
| `perPage` | `Integer` | Query, Optional | This parameter indicates how many records to fetch in each request. Default value is 20. The maximum allowed values is 200; any per_page value over 200 will be changed to 200.<br>Use in query `per_page=200`.<br>**Default**: `20`<br>**Constraints**: `<= 200` |
| `direction` | [`ListMetafieldsInputDirection`](../../doc/models/containers/list-metafields-input-direction.md) | Query, Optional | This is a container for one-of cases. |
| `direction` | [`SortingDirection`](../../doc/models/sorting-direction.md) | Query, Optional | Controls the order in which results are returned.<br>Use in query `direction=asc`. |

## Response Type

Expand Down Expand Up @@ -556,7 +556,7 @@ PaginatedMetadata listMetadata(
| `endDatetime` | `String` | Query, Optional | The end date and time (format YYYY-MM-DD HH:MM:SS) with which to filter the date_field. Returns metadata with a timestamp at or before exact time provided in query. You can specify timezone in query - otherwise your site's time zone will be used. If provided, this parameter will be used instead of end_date. |
| `withDeleted` | `Boolean` | Query, Optional | Allow to fetch deleted metadata. |
| `resourceIds` | `List<Integer>` | Query, Optional | Allow to fetch metadata for multiple records based on provided ids. Use in query: `resource_ids[]=122&resource_ids[]=123&resource_ids[]=124`.<br>**Constraints**: *Maximum Items*: `50` |
| `direction` | [`ListMetadataInputDirection`](../../doc/models/containers/list-metadata-input-direction.md) | Query, Optional | This is a container for one-of cases. |
| `direction` | [`SortingDirection`](../../doc/models/sorting-direction.md) | Query, Optional | Controls the order in which results are returned.<br>Use in query `direction=asc`. |

## Response Type

Expand Down
2 changes: 1 addition & 1 deletion doc/controllers/customers.md
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ List<CustomerResponse> listCustomers(

| Parameter | Type | Tags | Description |
| --- | --- | --- | --- |
| `direction` | [`ListCustomersInputDirection`](../../doc/models/containers/list-customers-input-direction.md) | Query, Optional | This is a container for one-of cases. |
| `direction` | [`SortingDirection`](../../doc/models/sorting-direction.md) | Query, Optional | Direction to sort customers by time of creation |
| `page` | `Integer` | Query, Optional | Result records are organized in pages. By default, the first page of results is displayed. The page parameter specifies a page number of results to fetch. You can start navigating through the pages to consume the results. You do this by passing in a page parameter. Retrieve the next page by adding ?page=2 to the query string. If there are no results to return, then an empty result set will be returned.<br>Use in query `page=1`.<br>**Default**: `1`<br>**Constraints**: `>= 1` |
| `perPage` | `Integer` | Query, Optional | This parameter indicates how many records to fetch in each request. Default value is 50. The maximum allowed values is 200; any per_page value over 200 will be changed to 200.<br>Use in query `per_page=200`.<br>**Default**: `50`<br>**Constraints**: `<= 200` |
| `dateField` | [`BasicDateField`](../../doc/models/basic-date-field.md) | Query, Optional | The type of filter you would like to apply to your search.<br>Use in query: `date_field=created_at`. |
Expand Down
Loading