投稿の登録

POST/boards/{boardId}/posts

投稿を登録する。

Authorization

oauth2

Authorization Code OAuth Flow

Authorization URL - https://auth.worksmobile.com/oauth2/v2.0/authorize
Token URL - https://auth.worksmobile.com/oauth2/v2.0/token
Refresh URL - https://auth.worksmobile.com/oauth2/v2.0/token

Scope

board

HTTP Request

POSThttps://www.worksapis.com/v1.0/boards/{boardId}/posts

Path Parameters

ParameterTypeDescription
boardIdinteger

掲示板ID


required
example : 100
format : int64

Header Parameters

HeadertypeDescription
Authorizationstring

Bearer {token}


required
Content-Typestring

application/json


required
example : application/json

Request Body

PropertyTypeDescription
titlestring

件名


required
minLength : 1
maxLength : 200
bodystring

内容


required
minLength : 1
maxLength : 716800
enableCommentboolean

コメント許可フラグ


default : true
mustReadDaysinteger

必読期間(単位:日)


default : 0
minimum : 0
maximum : 30
format : int32
sendNotificationsboolean

投稿通知送信フラグ


default : true

Request Example

example

1{
2  "title": "Example title",
3  "body": "<h1>Example</h1> Insert body here.",
4  "enableComment": true,
5  "mustReadDays": 0,
6  "sendNotifications": true
7}

Response

HTTP 201

OK

PropertyTypeDescription
boardIdinteger

掲示板ID


format : int64
postIdinteger

投稿ID


format : int64
titlestring

件名


required
readCountinteger

既読数


format : int64
commentCountinteger

コメント数


format : int64
fileCountinteger

ファイル数


format : int64
createdTimestring

登録日時


required
format : date-time
readOnly : true
modifiedTimestring

更新日時


format : date-time
readOnly : true
isMustReadboolean

必読フラグ

bodystring

内容(タイプ:HTML)


required
enableCommentboolean

コメント許可フラグ

userIdstring

readOnly : true
nullable : true
userNamestring

登録者名


readOnly : true

Response Example

example

1{
2  "boardId": 100,
3  "postId": 1,
4  "title": "Example title",
5  "readCount": 0,
6  "commentCount": 0,
7  "fileCount": 0,
8  "createdTime": "2022-10-28T17:26:35+09:00",
9  "modifiedTime": "2022-10-28T17:26:35+09:00",
10  "isMustRead": true,
11  "body": "<h1>Example</h1> Insert body here.",
12  "enableComment": true,
13  "userId": "userf7da-f82c-4284-13e7-030f3b4c756x",
14  "userName": "Susan Nielsen"
15}

HTTP 403

Forbidden