Skip to content

Commit 10ca8e2

Browse files
authored
Merge pull request #412 from mikekistler/naming-date-time-values
Add naming guidance for date-time values
2 parents 003fd11 + 83cedaa commit 10ca8e2

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

azure/ConsiderationsForServiceDesign.md

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,10 @@ For example, `collectedItems` not `itemsCollected`
116116

117117
For example, `nextUrl` not `nextURL`.
118118

119+
:ballot_box_with_check: **YOU SHOULD** use an "At" suffix in names of `date-time` values.
120+
121+
For example, `createdAt` not `created` or `createdDateTime`.
122+
119123
:ballot_box_with_check: **YOU SHOULD** use a suffix of the unit of measurement for values with a clear unit of measurement (such as bytes, miles, and so on). Use a generally accepted abbreviation for the units (e.g. "Km" rather than "Kilometers") when appropriate.
120124

121125
:ballot_box_with_check: **YOU SHOULD** use an int for time durations and include the time units in the name.
@@ -140,8 +144,9 @@ The following are recommended names for properties that match the associated des
140144

141145
| Name | Description |
142146
|------------- | --- |
143-
| createdDateTime | The date-time that the resource was created |
144-
| updatedDateTime | The date-time that the resource was last updated/modified |
147+
| createdAt | The date and time the resource was created. |
148+
| lastModifiedAt | The date and time the resource was last modified. |
149+
| deletedAt | The date and time the resource was deleted. |
145150
| kind | The discriminator value for a polymorphic resource |
146151

147152
### `name` vs `id`

0 commit comments

Comments
 (0)