Skip to content

Commit

Permalink
docs: update openapi spec to include info about passing in timestamps…
Browse files Browse the repository at this point in the history
… for topic creation, removing timestamp as valid request param for topic replying
  • Loading branch information
julianlam committed Feb 13, 2023
1 parent 326b926 commit 40e7b86
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
9 changes: 9 additions & 0 deletions public/openapi/write/topics.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,15 @@ post:
content:
type: string
example: This is the test topic's content
timestamp:
type: number
description: |
A UNIX timestamp of the topic's creation date (i.e. when it will be posted).
Specifically, this value can only be set to a value in the future if the calling user has the `topics:schedule` privilege for the passed-in category.
Otherwise, the current date and time are always assumed.
In some scenarios (e.g. forum migrations), you may want to backdate topics and posts.
Please see [this Developer FAQ topic](https://community.nodebb.org/topic/16983/how-can-i-backdate-topics-and-posts-for-migration-purposes) for more information.
example: 556084800000
tags:
type: array
items:
Expand Down
2 changes: 0 additions & 2 deletions public/openapi/write/topics/tid.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,6 @@ post:
content:
type: string
example: This is a test reply
timestamp:
type: number
toPid:
type: number
required:
Expand Down

0 comments on commit 40e7b86

Please sign in to comment.