Skip to content

Commit 9223e25

Browse files
committed
docs(promotions): PROMO-933 remove prefix and suffix and add more code settings to response
remove prefix and suffix and add more code settings to response change to capital letters
1 parent 56895c5 commit 9223e25

File tree

1 file changed

+24
-28
lines changed

1 file changed

+24
-28
lines changed

reference/promotions.v3.yml

Lines changed: 24 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,7 @@ paths:
207207
208208
**Note:**
209209
* batch_size is limited to 250 codes per request for first version. If batch_size is not an integer or larger than 250, it will return a 422 error code.
210-
* The default rate limit for this endpoint is 40 concurrent requests.
210+
* The default rate limit for this endpoint is 10 concurrent requests.
211211
operationId: generatePromotionCodesBatch
212212
parameters:
213213
- $ref: '#/components/parameters/ContentType'
@@ -221,20 +221,6 @@ paths:
221221
- batch_size
222222
type: object
223223
properties:
224-
prefix:
225-
type: string
226-
description: A prefix to add to the generated codes.
227-
example: 'PROMO-'
228-
minLength: 1
229-
maxLength: 20
230-
pattern: '[a-zA-Z0-9_\ -]'
231-
suffix:
232-
type: string
233-
description: A suffix to add to the generated codes.
234-
example: '2025'
235-
minLength: 1
236-
maxLength: 20
237-
pattern: '[a-zA-Z0-9_\ -]'
238224
batch_size:
239225
type: integer
240226
description: The number of coupon codes to generate in each batch. The maximum value is 250.
@@ -255,7 +241,7 @@ paths:
255241
maximum: 100000
256242
required: true
257243
responses:
258-
'200':
244+
'201':
259245
$ref: '#/components/responses/BulkCouponCodesResponse'
260246
'400':
261247
description: Invalid request.
@@ -264,13 +250,13 @@ paths:
264250
schema:
265251
$ref: '#/components/schemas/ErrorResponse400'
266252
'403':
267-
description: The request payload was invalid.
253+
description: Forbidden.
268254
content:
269255
application/json:
270256
schema:
271257
$ref: '#/components/schemas/ErrorResponse403'
272258
'422':
273-
description: The request payload was invalid.
259+
description: The request payload is invalid.
274260
content:
275261
application/json:
276262
schema:
@@ -1405,11 +1391,11 @@ components:
14051391
properties:
14061392
code:
14071393
type: string
1408-
pattern: '[a-zA-Z0-9_\ -]'
1409-
description: A unique code that can be used to manually apply a discount. Only letters, numbers, white spaces, underscores and hyphens are allowed.
1410-
example: TEST-COUPON-CODE
1411-
maxLength: 50
1412-
minLength: 12
1394+
pattern: '^[A-Z0-9]{16}$'
1395+
description: A unique, 16-character code that can be used to manually apply a discount. The code consists of randomly generated capital letters and numbers.
1396+
example: 'OMHYFQ4S26EY63UW'
1397+
maxLength: 16
1398+
minLength: 16
14131399

14141400
BulkCouponCodes:
14151401
type: array
@@ -1756,11 +1742,21 @@ components:
17561742
example-1:
17571743
value:
17581744
data:
1759-
- code: "PROMO-abc123-2025"
1760-
- code: "PROMO-def456-2025"
1761-
- code: "PROMO-ghi789-2025"
1762-
- code: "PROMO-jkl012-2025"
1763-
- code: "PROMO-mno345-2025"
1745+
- max_uses: 10
1746+
max_uses_per_customer: 5
1747+
current_uses: 0
1748+
created: '2019-01-20T22:00:00+00:00'
1749+
codes:
1750+
- id: 1
1751+
code: "WFYUYQM1W1ZYGK7S"
1752+
- id: 2
1753+
code: "TQ4PBBEK9SCZ212Z"
1754+
- id: 3
1755+
code: "B2YKV43O18LPJGNS"
1756+
- id: 4
1757+
code: "OSGJJBV3WBRC3G7X"
1758+
- id: 5
1759+
code: "XA8JS9T2N0C2TGS3"
17641760
meta: {}
17651761

17661762
PromotionCodeResponse:

0 commit comments

Comments
 (0)