-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #9 from square/release/5.1.0.20200325
release
- Loading branch information
Showing
72 changed files
with
1,738 additions
and
659 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
17 changes: 17 additions & 0 deletions
17
doc/models/catalog-custom-attribute-definition-app-visibility.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
## Catalog Custom Attribute Definition App Visibility | ||
|
||
Defines the visibility of a custom attribute to applications other than their | ||
creating application. | ||
|
||
### Enumeration | ||
|
||
`CatalogCustomAttributeDefinitionAppVisibility` | ||
|
||
### Fields | ||
|
||
| Name | Description | | ||
| --- | --- | | ||
| `APPVISIBILITYHIDDEN` | Other applications cannot read this custom attribute. | | ||
| `APPVISIBILITYREADONLY` | Other applications can read this custom attribute definition and<br>values. | | ||
| `APPVISIBILITYREADWRITEVALUES` | Other applications can read and write custom attribute values on objects.<br>They can read but cannot edit the custom attribute definition. | | ||
|
24 changes: 24 additions & 0 deletions
24
...alog-custom-attribute-definition-selection-config-custom-attribute-selection.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
## Catalog Custom Attribute Definition Selection Config Custom Attribute Selection | ||
|
||
A named selection for this `SELECTION`-type custom attribute definition. | ||
|
||
### Structure | ||
|
||
`CatalogCustomAttributeDefinitionSelectionConfigCustomAttributeSelection` | ||
|
||
### Fields | ||
|
||
| Name | Type | Tags | Description | | ||
| --- | --- | --- | --- | | ||
| `Uid` | `String` | Optional | Unique ID set by Square. | | ||
| `Name` | `String` | | Selection name, unique within `allowed_selections`.<br>Required. Min length of 1, max length of 255. | | ||
|
||
### Example (as JSON) | ||
|
||
```json | ||
{ | ||
"uid": null, | ||
"name": "name0" | ||
} | ||
``` | ||
|
24 changes: 24 additions & 0 deletions
24
doc/models/catalog-custom-attribute-definition-selection-config.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
## Catalog Custom Attribute Definition Selection Config | ||
|
||
Configuration associated with `SELECTION`-type custom attribute definitions. | ||
|
||
### Structure | ||
|
||
`CatalogCustomAttributeDefinitionSelectionConfig` | ||
|
||
### Fields | ||
|
||
| Name | Type | Tags | Description | | ||
| --- | --- | --- | --- | | ||
| `MaxAllowedSelections` | `Integer` | Optional | The maximum number of selections that can be set. The maximum value for this<br>attribute is 100. May be modified, but changing the value will not<br>affect existing custom attribute values on objects. Clients need to<br>handle Custom Attributes with more selected values than allowed by this limit. | | ||
| `AllowedSelections` | [`List<CatalogCustomAttributeDefinitionSelectionConfigCustomAttributeSelection>`](/doc/models/catalog-custom-attribute-definition-selection-config-custom-attribute-selection.md) | Optional | The set of valid `CatalogCustomAttributeSelections`. Up to a maximum of 100<br>selections can be defined. Can be modified. | | ||
|
||
### Example (as JSON) | ||
|
||
```json | ||
{ | ||
"max_allowed_selections": null, | ||
"allowed_selections": null | ||
} | ||
``` | ||
|
17 changes: 17 additions & 0 deletions
17
doc/models/catalog-custom-attribute-definition-seller-visibility.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
## Catalog Custom Attribute Definition Seller Visibility | ||
|
||
Defines the visibility of a custom attribute to sellers in Square | ||
client applications, Square APIs or in Square UIs (including Square Point | ||
of Sale applications and Square Dashboard). | ||
|
||
### Enumeration | ||
|
||
`CatalogCustomAttributeDefinitionSellerVisibility` | ||
|
||
### Fields | ||
|
||
| Name | Description | | ||
| --- | --- | | ||
| `SELLERVISIBILITYHIDDEN` | Sellers cannot read this custom attribute in Square client<br>applications or Square APIs. | | ||
| `SELLERVISIBILITYREADWRITEVALUES` | Sellers can read and write this custom attribute value in catalog objects,<br>but cannot edit the custom attribute definition. | | ||
|
22 changes: 22 additions & 0 deletions
22
doc/models/catalog-custom-attribute-definition-string-config.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
## Catalog Custom Attribute Definition String Config | ||
|
||
Configuration associated with Custom Attribute Definitions of type `STRING`. | ||
|
||
### Structure | ||
|
||
`CatalogCustomAttributeDefinitionStringConfig` | ||
|
||
### Fields | ||
|
||
| Name | Type | Tags | Description | | ||
| --- | --- | --- | --- | | ||
| `EnforceUniqueness` | `Boolean` | Optional | If true, each Custom Attribute instance associated with this Custom Attribute<br>Definition must have a unique value within the seller's catalog. For<br>example, this may be used for a value like a SKU that should not be<br>duplicated within a seller's catalog. May not be modified after the<br>definition has been created. | | ||
|
||
### Example (as JSON) | ||
|
||
```json | ||
{ | ||
"enforce_uniqueness": null | ||
} | ||
``` | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
## Catalog Custom Attribute Definition Type | ||
|
||
Defines the possible types for a custom attribute. | ||
|
||
### Enumeration | ||
|
||
`CatalogCustomAttributeDefinitionType` | ||
|
||
### Fields | ||
|
||
| Name | Description | | ||
| --- | --- | | ||
| `STRING` | A free-form string containing up to 255 characters. | | ||
| `BOOLEAN` | A `true` or `false` value. | | ||
| `NUMBER` | Integer divided by 100,000. | | ||
| `SELECTION` | One or more choices from `allowed_selections`. | | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
## Catalog Custom Attribute Definition | ||
|
||
Contains information defining a custom attribute. Custom attributes are | ||
intended to store additional information about a catalog object or to associate a | ||
catalog object with an entity in another system. Do not use custom attributes | ||
to store any sensitive information (personally identifiable information, card details, etc.). | ||
[Read more about custom attributes](https://developer.squareup.com/docs/catalog-api/add-custom-attributes) | ||
|
||
### Structure | ||
|
||
`CatalogCustomAttributeDefinition` | ||
|
||
### Fields | ||
|
||
| Name | Type | Tags | Description | | ||
| --- | --- | --- | --- | | ||
| `Type` | [`String`](/doc/models/catalog-custom-attribute-definition-type.md) | | Defines the possible types for a custom attribute. | | ||
| `Name` | `String` | | The name of this definition for API and seller-facing UI purposes.<br>The name must be unique within the (merchant, application_id) pair. Required.<br>May not be empty and may not exceed 255 characters. Can be modified after creation. | | ||
| `Description` | `String` | Optional | Seller-oriented description of the meaning of this Custom Attribute,<br>any constraints that the seller should observe, etc. May be displayed as a tooltip in Square UIs. | | ||
| `SourceApplication` | [`SourceApplication`](/doc/models/source-application.md) | Optional | Provides information about the application used to generate an inventory<br>change. | | ||
| `AllowedObjectTypes` | [`List<String>`](/doc/models/catalog-object-type.md) | Optional | The set of Catalog Object Types that this Custom Attribute may be applied to.<br>Currently, only `ITEM` and `ITEM_VARIATION` are allowed.<br>See [CatalogObjectType](#type-catalogobjecttype) for possible values | | ||
| `SellerVisibility` | [`String`](/doc/models/catalog-custom-attribute-definition-seller-visibility.md) | Optional | Defines the visibility of a custom attribute to sellers in Square<br>client applications, Square APIs or in Square UIs (including Square Point<br>of Sale applications and Square Dashboard). | | ||
| `AppVisibility` | [`String`](/doc/models/catalog-custom-attribute-definition-app-visibility.md) | Optional | Defines the visibility of a custom attribute to applications other than their<br>creating application. | | ||
| `StringConfig` | [`CatalogCustomAttributeDefinitionStringConfig`](/doc/models/catalog-custom-attribute-definition-string-config.md) | Optional | Configuration associated with Custom Attribute Definitions of type `STRING`. | | ||
| `SelectionConfig` | [`CatalogCustomAttributeDefinitionSelectionConfig`](/doc/models/catalog-custom-attribute-definition-selection-config.md) | Optional | Configuration associated with `SELECTION`-type custom attribute definitions. | | ||
| `CustomAttributeUsageCount` | `Integer` | Optional | __Read-only.__ The number of custom attributes that reference this<br>custom attribute definition. Set by the server in response to a ListCatalog<br>request with `include_counts` set to `true`. If the actual count is greater<br>than 100, `custom_attribute_usage_count` will be set to `100`. | | ||
| `Key` | `String` | Optional | The name of the desired custom attribute key that can be used to access<br>the custom attribute value on catalog objects. Cannot be modified after the<br>custom attribute definition has been created. | | ||
|
||
### Example (as JSON) | ||
|
||
```json | ||
{ | ||
"type": "NUMBER", | ||
"name": "name0", | ||
"description": null, | ||
"source_application": null, | ||
"allowed_object_types": null, | ||
"seller_visibility": null, | ||
"app_visibility": null, | ||
"string_config": null, | ||
"selection_config": null, | ||
"custom_attribute_usage_count": null, | ||
"key": null | ||
} | ||
``` | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
## Catalog Custom Attribute Value | ||
|
||
An instance of a custom attribute. Custom attributes can be defined and | ||
added to `ITEM` and `ITEM_VARIATION` type catalog objects. | ||
[Read more about custom attributes](https://developer.squareup.com/docs/catalog-api/add-custom-attributes). | ||
|
||
### Structure | ||
|
||
`CatalogCustomAttributeValue` | ||
|
||
### Fields | ||
|
||
| Name | Type | Tags | Description | | ||
| --- | --- | --- | --- | | ||
| `Name` | `String` | Optional | The name of the custom attribute. | | ||
| `StringValue` | `String` | Optional | The string value of the custom attribute. Populated if `type` = `STRING`. | | ||
| `CustomAttributeDefinitionId` | `String` | Optional | __Read-only.__ The custom attribute definition this value belongs to. | | ||
| `Type` | [`String`](/doc/models/catalog-custom-attribute-definition-type.md) | Optional | Defines the possible types for a custom attribute. | | ||
| `NumberValue` | `String` | Optional | Populated if `type` = `NUMBER`. Contains a string<br>representation of a decimal number, using a `.` as the decimal separator. | | ||
| `BooleanValue` | `Boolean` | Optional | A `true` or `false` value. Populated if `type` = `BOOLEAN`. | | ||
| `SelectionUidValues` | `List<String>` | Optional | One or more choices from `allowed_selections`. Populated if `type` = `SELECTION`. | | ||
| `Key` | `String` | Optional | __Read-only.__ A copy of key from the associated custom attribute definition. | | ||
|
||
### Example (as JSON) | ||
|
||
```json | ||
{ | ||
"name": null, | ||
"string_value": null, | ||
"custom_attribute_definition_id": null, | ||
"type": null, | ||
"number_value": null, | ||
"boolean_value": null, | ||
"selection_uid_values": null, | ||
"key": null | ||
} | ||
``` | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.