توضیحات
هر عملیات در این گروه: آنچه میپذیرد، آنچه برمیگرداند و خطاهایی که ممکن است با آنها پاسخ دهد.
عملیاتها
Private notes pinned to a thread, the Notes panel of the reading pane.
Notes are private to a person. A key reads and writes the notes of the workspace owner, and an app those of the person who connected it. A key or an app limited to particular addresses reaches only the notes on threads that arrived at them.
GET/threads/{id}/notes
List the notes on a thread
Pinned notes first, then the rest in the order they were arranged. Notes are private to a person. A key reads and writes the notes of the workspace owner, and an app those of the person who connected it.
Requires the threads:read scope.
پارامترهای مسیر
idstringالزامیThe thread the notes are on, as
GET /threadsreturns it.
خروجی
Every note on the thread, in display order.
خطاها
خطاهایی که هر عملیاتی ممکن است برگرداند400401403404422500فهرست خطاها
همچنین در دسترس در
POST/threads/{id}/notes
Add a note to a thread
A new note goes after the others. color is one of the eight the app offers, and pinned keeps it at the top. Notes are private to a person. A key reads and writes the notes of the workspace owner, and an app those of the person who connected it.
Requires the threads:write scope.
پارامترهای مسیر
idstringالزامیThe thread the notes are on, as
GET /threadsreturns it.
بدنهٔ درخواست
contentstringالزامیThe text of the note, up to 20,000 characters. Leading and trailing spaces are trimmed.
1 تا 20000 نویسهcolorstringOne of the eight the app offers:
default,red,orange,yellow,green,blue,purpleorpink. Defaults todefault.یکی از"default""red""orange""yellow""green""blue""purple""pink"pinnedbooleanKeeps the note above the others. Defaults to false.
خروجی
The note.
خطاها
خطاهایی که هر عملیاتی ممکن است برگرداند400401403404422500فهرست خطاها
همچنین در دسترس در
POST/threads/{id}/notes/reorder
Arrange the notes on a thread
Sets the order of every note on the thread at once, first to last. Pinned notes still come first. ids has to name each note exactly once, or the call is a 422 invalid_parameter on ids and nothing moves.
Requires the threads:write scope.
پارامترهای مسیر
idstringالزامیThe thread the notes are on, as
GET /threadsreturns it.
بدنهٔ درخواست
idsstring[]الزامی- 1 تا 200 مورد
خروجی
The notes, in their new order.
خطاها
خطاهایی که هر عملیاتی ممکن است برگرداند400401403404422500فهرست خطاها
همچنین در دسترس در
PATCH/threads/{id}/notes/{noteId}
Change a note
Changes its text, its colour or whether it is pinned. Give at least one. A note id that is not on this thread is a 404.
Requires the threads:write scope.
پارامترهای مسیر
idstringالزامیThe thread the notes are on, as
GET /threadsreturns it.noteIdstringالزامیThe id of a note on that thread.
بدنهٔ درخواست
contentstringThe new text, up to 20,000 characters.
1 تا 20000 نویسهcolorstringThe new colour.
یکی از"default""red""orange""yellow""green""blue""purple""pink"pinnedbooleanPins or unpins it.
خروجی
The note as it is now.
خطاها
خطاهایی که هر عملیاتی ممکن است برگرداند400401403404422500فهرست خطاها
همچنین در دسترس در
DELETE/threads/{id}/notes/{noteId}
Delete a note
Gone for good. There is no bin for notes.
Requires the threads:write scope.
پارامترهای مسیر
idstringالزامیThe thread the notes are on, as
GET /threadsreturns it.noteIdstringالزامیThe id of a note on that thread.
خروجی
Deleted.
خطاها
خطاهایی که هر عملیاتی ممکن است برگرداند400401403404422500فهرست خطاها
همچنین در دسترس در
اشیا
DeletedThreadNoteobject
objectstring- یکی از
"note" idstringthreadIdstringdeletedboolean- یکی از
true
ThreadNoteobject
objectstringالزامی- یکی از
"note" idstringالزامیthreadIdstringالزامیcontentstringالزامی- تا 20000 نویسه
colorstringالزامی- یکی از
"default""red""orange""yellow""green""blue""purple""pink" pinnedbooleanالزامیPinned notes are listed before the others.
orderintegerالزامیWhere it sits among the notes that share its pinned state, lowest first.
createdAtstringالزامی- قالب
date-time updatedAtstringالزامی- قالب
date-time
ThreadNoteListobject
objectstring- یکی از
"list" dataThreadNote[]