Skip to content

Commit 6d4cd1e

Browse files
committed
Updated API from documentation release
1 parent ddd8ebb commit 6d4cd1e

File tree

2 files changed

+50
-8
lines changed

2 files changed

+50
-8
lines changed

api-specs/import/annotationTypes/annotations.raml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ annotationTypes:
1515
and thus supports namespaces (e.g. "common.LocalizedString" ).
1616
Must be mapped to a native/generated data type (e.g. "java.lang.String").
1717
type: string
18+
beta:
19+
type: boolean
1820
package:
1921
description: |
2022
Allows to specify a target package for a generator for a RAML library.

api-specs/import/types/import-container.raml

Lines changed: 48 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,16 +7,45 @@ uses:
77
annotations: ../annotationTypes/annotations.raml
88

99
types:
10+
StrategyEnum:
11+
description: The strategy of the retention policy. Used to determine how the ImportContainer should be retained.
12+
type: string
13+
(annotations.beta): true
14+
enum:
15+
- ttl
16+
(annotations.enumDescriptions):
17+
ttl: Time to live
18+
RetentionPolicy:
19+
description: The retention policy of the ImportContainer. If not set, the ImportContainer does not expire.
20+
discriminator: strategy
21+
properties:
22+
strategy:
23+
type: StrategyEnum
24+
TimeToLiveConfig:
25+
type: object
26+
(annotations.beta): true
27+
properties:
28+
timeToLive:
29+
description: The time to live of the ImportContainer. Used to generate the `expiresAt` value of the ImportContainer. The lowest accepted value is `1h` and the highest accepted value is `30d`.
30+
type: string
31+
pattern: '^(?:(\d+)d|(\d+)h|(\d+)m)$'
32+
TimeToLiveRetentionPolicy:
33+
type: RetentionPolicy
34+
description: Set a time to live retention policy for the ImportContainer.
35+
(annotations.beta): true
36+
discriminatorValue: ttl
37+
properties:
38+
config:
39+
type: TimeToLiveConfig
40+
description: The configuration of the time to live retention policy.
1041
ImportContainer:
1142
description: |
1243
Serves as the entry point of resources.
1344
An Import Container is not resource type-specific.
1445
example: !include ../examples/import-container-minimal.json
1546
properties:
1647
key:
17-
description: |
18-
User-defined unique identifier for the ImportContainer.
19-
Keys can only contain alphanumeric characters (a-Z, 0-9), underscores and hyphens (_, -).
48+
description: User-defined unique identifier for the ImportContainer.
2049
type: string
2150
resourceType?:
2251
description: |
@@ -27,27 +56,38 @@ types:
2756
description: The version of the ImportContainer.
2857
type: number
2958
format: int64
59+
retentionPolicy?:
60+
type: RetentionPolicy
61+
(annotations.beta): true
62+
description: The retention policy of the ImportContainer.
3063
createdAt:
31-
description: The time when the ImportContainer was created.
64+
description: Date and time (UTC) the ImportContainer was initially created.
3265
type: datetime
3366
lastModifiedAt:
34-
description: The last time when the ImportContainer was modified.
67+
description: Date and time (UTC) the ImportContainer was last updated.
68+
type: datetime
69+
expiresAt?:
3570
type: datetime
71+
(annotations.beta): true
72+
description: Date and time (UTC) the ImportContainer is automatically deleted. Only present if a `retentionPolicy` is set. ImportContainers without `expiresAt` are permanent until [manually deleted](#delete-importcontainer).
3673
ImportContainerDraft:
3774
description: |
3875
The representation sent to the server when creating an [ImportContainer](#importcontainer).
3976
example: !include ../examples/import-container-draft-minimal.json
4077
properties:
4178
key:
42-
description: |
43-
User-defined unique identifier of the ImportContainer.
44-
Keys can only contain alphanumeric characters (a-Z, 0-9), underscores and hyphens (_, -).
79+
description: User-defined unique identifier of the ImportContainer.
4580
type: string
81+
pattern: ^[a-zA-Z0-9_-]+$
4682
resourceType?:
4783
description: |
4884
The [resource type](#importresourcetype) to be imported.
4985
If not given, the ImportContainer is able to import all of the supported [ImportResourceTypes](#importresourcetype).
5086
type: common.ImportResourceType
87+
retentionPolicy?:
88+
type: RetentionPolicy
89+
(annotations.beta): true
90+
description: Set a retention policy to automatically delete the ImportContainer after a defined period.
5191
ImportContainerUpdateDraft:
5292
description: |
5393
The representation sent to the server when updating an Import Container.

0 commit comments

Comments
 (0)