{ "opencollection": "1.0.0", "info": { "name": "Square ApplePay OrderCustomAttributes API", "version": "2.0" }, "items": [ { "info": { "name": "OrderCustomAttributes", "type": "folder" }, "items": [ { "info": { "name": "Square List Order Custom Attribute Definitions", "type": "http" }, "http": { "method": "GET", "url": "https://connect.squareup.com/v2/orders/custom-attribute-definitions", "params": [ { "name": "visibility_filter", "value": "", "type": "query", "description": "Requests that all of the custom attributes be returned, or only those that are read-only or read-write." }, { "name": "cursor", "value": "", "type": "query", "description": "The cursor returned in the paged response from the previous call to this endpoint. \nProvide this cursor to retrieve the next page of results for your original request. \nFor more information, see [Pagination](https://developer.squareup.com/docs/working-with-apis/pagination)." }, { "name": "limit", "value": "", "type": "query", "description": "The maximum number of results to return in a single paged response. This limit is advisory. \nThe response might contain more or fewer results. The minimum value is 1 and the maximum value is 100. \nThe default value is 20.\nFor more information, see [Pagination](https://developer.squareup.com/docs/working-with-apis/pagination)." } ], "auth": { "type": "oauth2", "flow": "authorization_code", "authorizationUrl": "https://connect.squareup.com/oauth2/authorize", "accessTokenUrl": "https://connect.squareup.com/oauth2/token", "credentials": { "clientId": "{{clientId}}", "clientSecret": "{{clientSecret}}" } } }, "docs": "Lists the order-related [custom attribute definitions](entity:CustomAttributeDefinition) that belong to a Square seller account.\n\nWhen all response pages are retrieved, the results include all custom attribute definitions\nthat are visible to the requesting application, including those that are created by other\napplications and set to `VISIBILITY_READ_ONLY` or `VISIBILITY_READ_WRITE_VALUES`. Note that\nseller-defined custom attributes (also known as custom fields) are always set to `VISIBILITY_REA" }, { "info": { "name": "Square Create Order Custom Attribute Definition", "type": "http" }, "http": { "method": "POST", "url": "https://connect.squareup.com/v2/orders/custom-attribute-definitions", "body": { "type": "json", "data": "{}" }, "auth": { "type": "oauth2", "flow": "authorization_code", "authorizationUrl": "https://connect.squareup.com/oauth2/authorize", "accessTokenUrl": "https://connect.squareup.com/oauth2/token", "credentials": { "clientId": "{{clientId}}", "clientSecret": "{{clientSecret}}" } } }, "docs": "Creates an order-related custom attribute definition. Use this endpoint to\ndefine a custom attribute that can be associated with orders.\n\nAfter creating a custom attribute definition, you can set the custom attribute for orders\nin the Square seller account." }, { "info": { "name": "Square Retrieve Order Custom Attribute Definition", "type": "http" }, "http": { "method": "GET", "url": "https://connect.squareup.com/v2/orders/custom-attribute-definitions/:key", "params": [ { "name": "key", "value": "", "type": "path", "description": "The key of the custom attribute definition to retrieve." }, { "name": "version", "value": "", "type": "query", "description": "To enable [optimistic concurrency](https://developer.squareup.com/docs/build-basics/common-api-patterns/optimistic-concurrency)\ncontrol, include this optional field and specify the current version of the custom attribute." } ], "auth": { "type": "oauth2", "flow": "authorization_code", "authorizationUrl": "https://connect.squareup.com/oauth2/authorize", "accessTokenUrl": "https://connect.squareup.com/oauth2/token", "credentials": { "clientId": "{{clientId}}", "clientSecret": "{{clientSecret}}" } } }, "docs": "Retrieves an order-related [custom attribute definition](entity:CustomAttributeDefinition) from a Square seller account.\n\nTo retrieve a custom attribute definition created by another application, the `visibility`\nsetting must be `VISIBILITY_READ_ONLY` or `VISIBILITY_READ_WRITE_VALUES`. Note that seller-defined custom attributes\n(also known as custom fields) are always set to `VISIBILITY_READ_WRITE_VALUES`." }, { "info": { "name": "Square Update Order Custom Attribute Definition", "type": "http" }, "http": { "method": "PUT", "url": "https://connect.squareup.com/v2/orders/custom-attribute-definitions/:key", "params": [ { "name": "key", "value": "", "type": "path", "description": "The key of the custom attribute definition to update." } ], "body": { "type": "json", "data": "{}" }, "auth": { "type": "oauth2", "flow": "authorization_code", "authorizationUrl": "https://connect.squareup.com/oauth2/authorize", "accessTokenUrl": "https://connect.squareup.com/oauth2/token", "credentials": { "clientId": "{{clientId}}", "clientSecret": "{{clientSecret}}" } } }, "docs": "Updates an order-related custom attribute definition for a Square seller account.\n\nOnly the definition owner can update a custom attribute definition. Note that sellers can view all custom attributes in exported customer data, including those set to `VISIBILITY_HIDDEN`." }, { "info": { "name": "Square Delete Order Custom Attribute Definition", "type": "http" }, "http": { "method": "DELETE", "url": "https://connect.squareup.com/v2/orders/custom-attribute-definitions/:key", "params": [ { "name": "key", "value": "", "type": "path", "description": "The key of the custom attribute definition to delete." } ], "auth": { "type": "oauth2", "flow": "authorization_code", "authorizationUrl": "https://connect.squareup.com/oauth2/authorize", "accessTokenUrl": "https://connect.squareup.com/oauth2/token", "credentials": { "clientId": "{{clientId}}", "clientSecret": "{{clientSecret}}" } } }, "docs": "Deletes an order-related [custom attribute definition](entity:CustomAttributeDefinition) from a Square seller account.\n\nOnly the definition owner can delete a custom attribute definition." }, { "info": { "name": "Square Bulk Delete Order Custom Attributes", "type": "http" }, "http": { "method": "POST", "url": "https://connect.squareup.com/v2/orders/custom-attributes/bulk-delete", "body": { "type": "json", "data": "{}" }, "auth": { "type": "oauth2", "flow": "authorization_code", "authorizationUrl": "https://connect.squareup.com/oauth2/authorize", "accessTokenUrl": "https://connect.squareup.com/oauth2/token", "credentials": { "clientId": "{{clientId}}", "clientSecret": "{{clientSecret}}" } } }, "docs": "Deletes order [custom attributes](entity:CustomAttribute) as a bulk operation.\n\nUse this endpoint to delete one or more custom attributes from one or more orders.\nA custom attribute is based on a custom attribute definition in a Square seller account. (To create a\ncustom attribute definition, use the [CreateOrderCustomAttributeDefinition](api-endpoint:OrderCustomAttributes-CreateOrderCustomAttributeDefinition) endpoint.)\n\nThis `BulkDeleteOrderCustomAttributes` endpoint accepts a map of 1 to 25 " }, { "info": { "name": "Square Bulk Upsert Order Custom Attributes", "type": "http" }, "http": { "method": "POST", "url": "https://connect.squareup.com/v2/orders/custom-attributes/bulk-upsert", "body": { "type": "json", "data": "{}" }, "auth": { "type": "oauth2", "flow": "authorization_code", "authorizationUrl": "https://connect.squareup.com/oauth2/authorize", "accessTokenUrl": "https://connect.squareup.com/oauth2/token", "credentials": { "clientId": "{{clientId}}", "clientSecret": "{{clientSecret}}" } } }, "docs": "Creates or updates order [custom attributes](entity:CustomAttribute) as a bulk operation.\n\nUse this endpoint to delete one or more custom attributes from one or more orders.\nA custom attribute is based on a custom attribute definition in a Square seller account. (To create a\ncustom attribute definition, use the [CreateOrderCustomAttributeDefinition](api-endpoint:OrderCustomAttributes-CreateOrderCustomAttributeDefinition) endpoint.)\n\nThis `BulkUpsertOrderCustomAttributes` endpoint accepts a map " }, { "info": { "name": "Square List Order Custom Attributes", "type": "http" }, "http": { "method": "GET", "url": "https://connect.squareup.com/v2/orders/:order_id/custom-attributes", "params": [ { "name": "order_id", "value": "", "type": "path", "description": "The ID of the target [order](entity:Order)." }, { "name": "visibility_filter", "value": "", "type": "query", "description": "Requests that all of the custom attributes be returned, or only those that are read-only or read-write." }, { "name": "cursor", "value": "", "type": "query", "description": "The cursor returned in the paged response from the previous call to this endpoint. \nProvide this cursor to retrieve the next page of results for your original request. \nFor more information, see [Pagination](https://developer.squareup.com/docs/working-with-apis/pagination)." }, { "name": "limit", "value": "", "type": "query", "description": "The maximum number of results to return in a single paged response. This limit is advisory. \nThe response might contain more or fewer results. The minimum value is 1 and the maximum value is 100. \nThe default value is 20.\nFor more information, see [Pagination](https://developer.squareup.com/docs/working-with-apis/pagination)." }, { "name": "with_definitions", "value": "", "type": "query", "description": "Indicates whether to return the [custom attribute definition](entity:CustomAttributeDefinition) in the `definition` field of each\ncustom attribute. Set this parameter to `true` to get the name and description of each custom attribute, \ninformation about the data type, or other definition details. The default value is `false`." } ], "auth": { "type": "oauth2", "flow": "authorization_code", "authorizationUrl": "https://connect.squareup.com/oauth2/authorize", "accessTokenUrl": "https://connect.squareup.com/oauth2/token", "credentials": { "clientId": "{{clientId}}", "clientSecret": "{{clientSecret}}" } } }, "docs": "Lists the [custom attributes](entity:CustomAttribute) associated with an order.\n\nYou can use the `with_definitions` query parameter to also retrieve custom attribute definitions\nin the same call.\n\nWhen all response pages are retrieved, the results include all custom attributes that are\nvisible to the requesting application, including those that are owned by other applications\nand set to `VISIBILITY_READ_ONLY` or `VISIBILITY_READ_WRITE_VALUES`." }, { "info": { "name": "Square Retrieve Order Custom Attribute", "type": "http" }, "http": { "method": "GET", "url": "https://connect.squareup.com/v2/orders/:order_id/custom-attributes/:custom_attribute_key", "params": [ { "name": "order_id", "value": "", "type": "path", "description": "The ID of the target [order](entity:Order)." }, { "name": "custom_attribute_key", "value": "", "type": "path", "description": "The key of the custom attribute to retrieve. This key must match the key of an\nexisting custom attribute definition." }, { "name": "version", "value": "", "type": "query", "description": "To enable [optimistic concurrency](https://developer.squareup.com/docs/build-basics/common-api-patterns/optimistic-concurrency)\ncontrol, include this optional field and specify the current version of the custom attribute." }, { "name": "with_definition", "value": "", "type": "query", "description": "Indicates whether to return the [custom attribute definition](entity:CustomAttributeDefinition) in the `definition` field of each \ncustom attribute. Set this parameter to `true` to get the name and description of each custom attribute, \ninformation about the data type, or other definition details. The default value is `false`." } ], "auth": { "type": "oauth2", "flow": "authorization_code", "authorizationUrl": "https://connect.squareup.com/oauth2/authorize", "accessTokenUrl": "https://connect.squareup.com/oauth2/token", "credentials": { "clientId": "{{clientId}}", "clientSecret": "{{clientSecret}}" } } }, "docs": "Retrieves a [custom attribute](entity:CustomAttribute) associated with an order.\n\nYou can use the `with_definition` query parameter to also retrieve the custom attribute definition\nin the same call.\n\nTo retrieve a custom attribute owned by another application, the `visibility` setting must be\n`VISIBILITY_READ_ONLY` or `VISIBILITY_READ_WRITE_VALUES`. Note that seller-defined custom attributes\nalso known as custom fields) are always set to `VISIBILITY_READ_WRITE_VALUES`." }, { "info": { "name": "Square Upsert Order Custom Attribute", "type": "http" }, "http": { "method": "POST", "url": "https://connect.squareup.com/v2/orders/:order_id/custom-attributes/:custom_attribute_key", "params": [ { "name": "order_id", "value": "", "type": "path", "description": "The ID of the target [order](entity:Order)." }, { "name": "custom_attribute_key", "value": "", "type": "path", "description": "The key of the custom attribute to create or update. This key must match the key \nof an existing custom attribute definition." } ], "body": { "type": "json", "data": "{}" }, "auth": { "type": "oauth2", "flow": "authorization_code", "authorizationUrl": "https://connect.squareup.com/oauth2/authorize", "accessTokenUrl": "https://connect.squareup.com/oauth2/token", "credentials": { "clientId": "{{clientId}}", "clientSecret": "{{clientSecret}}" } } }, "docs": "Creates or updates a [custom attribute](entity:CustomAttribute) for an order.\n\nUse this endpoint to set the value of a custom attribute for a specific order.\nA custom attribute is based on a custom attribute definition in a Square seller account. (To create a\ncustom attribute definition, use the [CreateOrderCustomAttributeDefinition](api-endpoint:OrderCustomAttributes-CreateOrderCustomAttributeDefinition) endpoint.)\n\nTo create or update a custom attribute owned by another application, the `visib" }, { "info": { "name": "Square Delete Order Custom Attribute", "type": "http" }, "http": { "method": "DELETE", "url": "https://connect.squareup.com/v2/orders/:order_id/custom-attributes/:custom_attribute_key", "params": [ { "name": "order_id", "value": "", "type": "path", "description": "The ID of the target [order](entity:Order)." }, { "name": "custom_attribute_key", "value": "", "type": "path", "description": "The key of the custom attribute to delete. This key must match the key of an\nexisting custom attribute definition." } ], "auth": { "type": "oauth2", "flow": "authorization_code", "authorizationUrl": "https://connect.squareup.com/oauth2/authorize", "accessTokenUrl": "https://connect.squareup.com/oauth2/token", "credentials": { "clientId": "{{clientId}}", "clientSecret": "{{clientSecret}}" } } }, "docs": "Deletes a [custom attribute](entity:CustomAttribute) associated with a customer profile.\n\nTo delete a custom attribute owned by another application, the `visibility` setting must be\n`VISIBILITY_READ_WRITE_VALUES`. Note that seller-defined custom attributes\n(also known as custom fields) are always set to `VISIBILITY_READ_WRITE_VALUES`." } ] } ], "bundled": true }