Skip to content

Reviews

3 endpoints: send a post for review, approve a post, reject a post.

Send a post for review

POST /v1/posts/{post_id}/review

Asks the Project's reviewers to approve a draft. Optionally assign a person or a Team.

Permission: posts:write · Accepts Idempotency-Key · Answers 201

Path parameters

NameDescription
post_idThe post's id.

Body

FieldTypeRequiredDescription
assigned_user_idstringNo(up to 128 characters)
assigned_team_idstringNo(up to 128 characters)

Response

FieldTypeRequiredDescription
object"post_review"Yes
post_idstringYes(up to 128 characters)
review_statusin_review, approved, rejectedYes
curl -X POST https://api.nowscale.com/v1/posts/POST_ID/review \
  -H "Authorization: Bearer $NOWSCALE_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{ ... }'

Approve a post

POST /v1/posts/{post_id}/review/approve

Approves the post's open review. Send expected_revision from the review to make sure you approve the version you checked.

Permission: reviews:write · Accepts Idempotency-Key

Path parameters

NameDescription
post_idThe post's id.

Body

FieldTypeRequiredDescription
expected_revisionintegerNo(0 to 9007199254740991)
reasonstringNo(up to 2000 characters)

Response

FieldTypeRequiredDescription
object"post_review"Yes
post_idstringYes(up to 128 characters)
review_statusin_review, approved, rejectedYes
curl -X POST https://api.nowscale.com/v1/posts/POST_ID/review/approve \
  -H "Authorization: Bearer $NOWSCALE_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{ ... }'

Reject a post

POST /v1/posts/{post_id}/review/reject

Rejects the post's open review with an optional reason for its author.

Permission: reviews:write · Accepts Idempotency-Key

Path parameters

NameDescription
post_idThe post's id.

Body

FieldTypeRequiredDescription
expected_revisionintegerNo(0 to 9007199254740991)
reasonstringNo(up to 2000 characters)

Response

FieldTypeRequiredDescription
object"post_review"Yes
post_idstringYes(up to 128 characters)
review_statusin_review, approved, rejectedYes
curl -X POST https://api.nowscale.com/v1/posts/POST_ID/review/reject \
  -H "Authorization: Bearer $NOWSCALE_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{ ... }'