From 3670e00652d6de64b9ac030da8cf1bf0f1d0622a Mon Sep 17 00:00:00 2001 From: Guilherme Moreira Date: Tue, 29 Mar 2022 14:58:22 -0600 Subject: [PATCH 1/5] [AG-1605] add external ID support --- openapi/platform/platform.yaml | 48 ++++++++++++++++++++++------------ 1 file changed, 32 insertions(+), 16 deletions(-) diff --git a/openapi/platform/platform.yaml b/openapi/platform/platform.yaml index d2ca6f82..9ccfb793 100644 --- a/openapi/platform/platform.yaml +++ b/openapi/platform/platform.yaml @@ -3644,6 +3644,9 @@ components: Custom fields associated with a sales order. The field definitions can be managed at Partner Center -> Administration -> Custom Fields. + One form of identifier should be choosen, either `fieldId` or `externalID`. + `fieldId` is the computer generated ID (like `FieldID-abc448ca-abc0-abc5-abc2-abc640bf4b99`) and `externalID` is a optional human-readable ID that can be set in the administration panel. + Dropdown possible value and the currency code are also configured in the Administration panel. x-examples: Custom Fields with string value Example: @@ -3764,7 +3767,10 @@ components: properties: fieldId: type: string - description: 'Field identifier, can be retrived by listing the attributes' + description: 'Field identifier, can be retrieved by listing the attributes' + externalID: + type: string + description: 'Alternative field identifier, can be set on admin panel and can be retrieved by listing the attributes' fieldType: type: string example: string @@ -3821,14 +3827,12 @@ components: readOnly: true title: type: string - description: 'The main label for the field, appering in most user interfaces that show the value. This field is not read when setting a value.' + description: 'The main label for the field, appearing in most user interfaces that show the value. This field is not read when setting a value.' readOnly: true description: type: string - description: 'A longer text explaination of the field, it optionally appears in the UI. This field is not read when setting a value.' + description: 'A longer text explanation of the field, it optionally appears in the UI. This field is not read when setting a value.' readOnly: true - required: - - fieldId required: - id - type @@ -4481,7 +4485,7 @@ components: properties: id: type: string - description: 'ID of custom fields, can be retrived using custom fields endpoint' + description: 'ID of custom fields, can be retrieved using custom fields endpoint' type: type: string example: customFields @@ -4555,6 +4559,9 @@ components: Custom fields associated with a sales account. The field definitions can be managed at Partner Center -> Administration -> Custom Fields. + One form of identifier should be choosen, either `fieldId` or `externalID`. + `fieldId` is the computer generated ID (like `FieldID-abc448ca-abc0-abc5-abc2-abc640bf4b99`) and `externalID` is a optional human-readable ID that can be set in the administration panel. + Dropdown possible value and the currency code are also configured in the Administration panel. x-examples: Custom Fields with string value Example: @@ -4672,7 +4679,10 @@ components: properties: fieldId: type: string - description: 'Field identifier, can be retrived by listing the attributes' + description: 'Field identifier, can be retrieved by listing the attributes' + externalID: + type: string + description: 'Alternative field identifier, can be set on admin panel and can be retrieved by listing the attributes' fieldType: type: string example: string @@ -4725,14 +4735,12 @@ components: readOnly: true title: type: string - description: 'The main label for the field, appering in most user interfaces that show the value. This field is not read when setting a value.' + description: 'The main label for the field, appearing in most user interfaces that show the value. This field is not read when setting a value.' readOnly: true description: type: string - description: 'A longer text explaination of the field, it optionally appears in the UI. This field is not read when setting a value.' + description: 'A longer text explanation of the field, it optionally appears in the UI. This field is not read when setting a value.' readOnly: true - required: - - fieldId required: - id - type @@ -4746,6 +4754,9 @@ components: Custom fields associated with a user. The field definitions can be managed at Partner Center -> Administration -> Custom Fields. + One form of identifier should be choosen, either `fieldId` or `externalID`. + `fieldId` is the computer generated ID (like `FieldID-abc448ca-abc0-abc5-abc2-abc640bf4b99`) and `externalID` is a optional human-readable ID that can be set in the administration panel. + Dropdown possible value and the currency code are also configured in the Administration panel. x-examples: Custom Fields with string value Example: @@ -4863,7 +4874,10 @@ components: properties: fieldId: type: string - description: 'Field identifier, can be retrived by listing the attributes' + description: 'Field identifier, can be retrieved by listing the attributes' + externalID: + type: string + description: 'Alternative field identifier, can be set on admin panel and can be retrieved by listing the attributes' fieldType: type: string example: string @@ -4922,8 +4936,6 @@ components: type: string description: 'A longer text explanation of the field, it optionally appears in the UI. This field is not read when setting a value.' readOnly: true - required: - - fieldId required: - id - type @@ -4937,6 +4949,9 @@ components: Custom fields associated with a product. These attributes can be managed at Partner Center -> Administration -> Data attributes. + One form of identifier should be choosen, either `fieldId` or `externalID`. + `fieldId` is the computer generated ID (like `FieldID-abc448ca-abc0-abc5-abc2-abc640bf4b99`) and `externalID` is a optional human-readable ID that can be set in the administration panel. + Dropdown possible values and the currency code are also configured in the Administration panel. x-tags: - Product Custom Fields @@ -4971,6 +4986,9 @@ components: fieldId: type: string description: 'Field identifier, can be retrieved by listing the attributes' + externalID: + type: string + description: 'Alternative field identifier, can be set on admin panel and can be retrieved by listing the attributes' fieldType: type: string example: string @@ -5029,8 +5047,6 @@ components: type: string description: 'A longer text explanation of the field, it optionally appears in the UI. This field is not read when setting a value.' readOnly: true - required: - - fieldId required: - id - type From 054bafe31e0f2474cd51c1c993c226e689392d9f Mon Sep 17 00:00:00 2001 From: Guilherme Moreira Date: Tue, 29 Mar 2022 15:50:28 -0600 Subject: [PATCH 2/5] [AG-1605] fix typo --- openapi/platform/platform.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/openapi/platform/platform.yaml b/openapi/platform/platform.yaml index 9ccfb793..db310b26 100644 --- a/openapi/platform/platform.yaml +++ b/openapi/platform/platform.yaml @@ -3644,7 +3644,7 @@ components: Custom fields associated with a sales order. The field definitions can be managed at Partner Center -> Administration -> Custom Fields. - One form of identifier should be choosen, either `fieldId` or `externalID`. + One form of identifier should be chosen, either `fieldId` or `externalID`. `fieldId` is the computer generated ID (like `FieldID-abc448ca-abc0-abc5-abc2-abc640bf4b99`) and `externalID` is a optional human-readable ID that can be set in the administration panel. Dropdown possible value and the currency code are also configured in the Administration panel. @@ -4559,7 +4559,7 @@ components: Custom fields associated with a sales account. The field definitions can be managed at Partner Center -> Administration -> Custom Fields. - One form of identifier should be choosen, either `fieldId` or `externalID`. + One form of identifier should be chosen, either `fieldId` or `externalID`. `fieldId` is the computer generated ID (like `FieldID-abc448ca-abc0-abc5-abc2-abc640bf4b99`) and `externalID` is a optional human-readable ID that can be set in the administration panel. Dropdown possible value and the currency code are also configured in the Administration panel. @@ -4754,7 +4754,7 @@ components: Custom fields associated with a user. The field definitions can be managed at Partner Center -> Administration -> Custom Fields. - One form of identifier should be choosen, either `fieldId` or `externalID`. + One form of identifier should be chosen, either `fieldId` or `externalID`. `fieldId` is the computer generated ID (like `FieldID-abc448ca-abc0-abc5-abc2-abc640bf4b99`) and `externalID` is a optional human-readable ID that can be set in the administration panel. Dropdown possible value and the currency code are also configured in the Administration panel. @@ -4949,7 +4949,7 @@ components: Custom fields associated with a product. These attributes can be managed at Partner Center -> Administration -> Data attributes. - One form of identifier should be choosen, either `fieldId` or `externalID`. + One form of identifier should be chosen, either `fieldId` or `externalID`. `fieldId` is the computer generated ID (like `FieldID-abc448ca-abc0-abc5-abc2-abc640bf4b99`) and `externalID` is a optional human-readable ID that can be set in the administration panel. Dropdown possible values and the currency code are also configured in the Administration panel. From 227475867066e25dcb1c646a02865837249b7aaa Mon Sep 17 00:00:00 2001 From: Guilherme Moreira Date: Tue, 29 Mar 2022 15:59:01 -0600 Subject: [PATCH 3/5] [AG-1605] remove .DS_Store --- openapi/.DS_Store | Bin 0 -> 6148 bytes 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 openapi/.DS_Store diff --git a/openapi/.DS_Store b/openapi/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..0378ca39dd8fadb3bb16e5c2306137d7e67c98dc GIT binary patch literal 6148 zcmeHK%}T>S5T0$TZV<5t!5(w*=AqUf@F0X*58i}`9#k|T)dtdRX;X{VNM1wV$S3f1 zoY~zLrF!uoQf6TGo1LFs_Dk3w01(Y#v;|NF0EtRiay+dW>68(1&g~ z8uVte+3_D4pl>Ik2MGj_!Kd#RCMv|(Ti8qDK~}H7i&D9=u(%|pT$U^H%I~O=p9R@) z&{q zW})|fKTTA6hp|cBB%hHPUY*=kA8mte=Xu3Gr$bY6$7Hu@>@+@l092z7Ds2Ti+Y1fLV1P3 lX$czoD8^hmifgD^(C?Cg=vgcbq6dX90-6SHn1MfK-~)vbQ*!_S literal 0 HcmV?d00001 From 22cf01fa3241c674cbf8971c9e51d404f8399003 Mon Sep 17 00:00:00 2001 From: Guilherme Moreira Date: Tue, 29 Mar 2022 16:00:58 -0600 Subject: [PATCH 4/5] [AG-1605] remove .DS_Store --- openapi/.DS_Store | Bin 6148 -> 0 bytes 1 file changed, 0 insertions(+), 0 deletions(-) delete mode 100644 openapi/.DS_Store diff --git a/openapi/.DS_Store b/openapi/.DS_Store deleted file mode 100644 index 0378ca39dd8fadb3bb16e5c2306137d7e67c98dc..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 6148 zcmeHK%}T>S5T0$TZV<5t!5(w*=AqUf@F0X*58i}`9#k|T)dtdRX;X{VNM1wV$S3f1 zoY~zLrF!uoQf6TGo1LFs_Dk3w01(Y#v;|NF0EtRiay+dW>68(1&g~ z8uVte+3_D4pl>Ik2MGj_!Kd#RCMv|(Ti8qDK~}H7i&D9=u(%|pT$U^H%I~O=p9R@) z&{q zW})|fKTTA6hp|cBB%hHPUY*=kA8mte=Xu3Gr$bY6$7Hu@>@+@l092z7Ds2Ti+Y1fLV1P3 lX$czoD8^hmifgD^(C?Cg=vgcbq6dX90-6SHn1MfK-~)vbQ*!_S From ab41b9aa1e93913abea8f67221de8ad352951bdb Mon Sep 17 00:00:00 2001 From: Guilherme Moreira Date: Wed, 30 Mar 2022 10:19:23 -0600 Subject: [PATCH 5/5] [AG-1605] add externalID example --- openapi/platform/platform.yaml | 52 ++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) diff --git a/openapi/platform/platform.yaml b/openapi/platform/platform.yaml index db310b26..46cb54aa 100644 --- a/openapi/platform/platform.yaml +++ b/openapi/platform/platform.yaml @@ -1281,6 +1281,19 @@ paths: dateValue: A good date value - fieldID: FieldID-abc448ca-abc0-abc5-abc2-abc640bf4b99 stringValue: A good string value + 'Example some fields using externalID instead of fieldId': + value: + data: + id: 'AG-1231231:ORD-1234567' + type: orderCustomFields + attributes: + partnerFields: + - externalId: days-active + integerValue: 1000 + - fieldId: FieldID-987448ca-abc0-abc5-abc2-abc640bf4b99 + dateValue: A good date value + - externalId: custom-nickname + stringValue: A good string value responses: '200': description: OK @@ -2473,6 +2486,19 @@ paths: dateValue: A good date value - fieldId: FieldID-abc448ca-abc0-abc5-abc2-abc640bf4b99 stringValue: A good string value + 'Example some fields using externalID instead of fieldId': + value: + data: + id: AG-1231231 + type: salesAccountCustomFields + attributes: + partnerFields: + - externalId: days-active + integerValue: 1000 + - fieldId: FieldID-987448ca-abc0-abc5-abc2-abc640bf4b99 + dateValue: A good date value + - externalId: custom-nickname + stringValue: A good string value responses: '200': description: OK @@ -2731,6 +2757,19 @@ paths: dateValue: A good date value - fieldId: FieldID-abc448ca-abc0-abc5-abc2-abc640bf4b99 stringValue: A good string value + 'Example some fields using externalID instead of fieldId': + value: + data: + id: U-12345678-abcd-1234-abcd-123456789abd + type: userCustomFields + attributes: + partnerFields: + - externalId: days-active + integerValue: 1000 + - fieldId: FieldID-987448ca-abc0-abc5-abc2-abc640bf4b99 + dateValue: A good date value + - externalId: custom-nickname + stringValue: A good string value responses: '200': description: OK @@ -2902,6 +2941,19 @@ paths: dateValue: A good date value - fieldId: FieldID-abc448ca-abc0-abc5-abc2-abc640bf4b99 stringValue: A good string value + 'Example some fields using externalID instead of fieldId': + value: + data: + id: ABC-MP-1234567890ABCDEFGHIJKLMNOPQRSTUV + type: productCustomFields + attributes: + partnerFields: + - externalId: days-active + integerValue: 1000 + - fieldId: FieldID-987448ca-abc0-abc5-abc2-abc640bf4b99 + dateValue: A good date value + - externalId: custom-nickname + stringValue: A good string value responses: '200': description: OK