DEV: Fix several type issues with the api docs (#14016)
`nullable` is no longer a valid type, and types also can't be an empty string, so just bringing a number of issues with types in compliance with the openapi spec.
This commit is contained in:
parent
29bb79de37
commit
65f6d46045
|
@ -39,25 +39,25 @@ describe 'groups' do
|
||||||
mentionable_level: { type: :integer },
|
mentionable_level: { type: :integer },
|
||||||
messageable_level: { type: :integer },
|
messageable_level: { type: :integer },
|
||||||
visibility_level: { type: :integer },
|
visibility_level: { type: :integer },
|
||||||
automatic_membership_email_domains: { type: :string, nullable: true },
|
automatic_membership_email_domains: { type: [:string, :null] },
|
||||||
automatic_membership_retroactive: { type: :boolean },
|
automatic_membership_retroactive: { type: :boolean },
|
||||||
primary_group: { type: :boolean },
|
primary_group: { type: :boolean },
|
||||||
title: { type: :string, nullable: true },
|
title: { type: [:string, :null] },
|
||||||
grant_trust_level: { type: :string, nullable: true },
|
grant_trust_level: { type: [:string, :null] },
|
||||||
incoming_email: { type: :string, nullable: true },
|
incoming_email: { type: [:string, :null] },
|
||||||
has_messages: { type: :boolean },
|
has_messages: { type: :boolean },
|
||||||
flair_url: { type: :string, nullable: true },
|
flair_url: { type: [:string, :null] },
|
||||||
flair_bg_color: { type: :string, nullable: true },
|
flair_bg_color: { type: [:string, :null] },
|
||||||
flair_color: { type: :string, nullable: true },
|
flair_color: { type: [:string, :null] },
|
||||||
bio_raw: { type: :string, nullable: true },
|
bio_raw: { type: [:string, :null] },
|
||||||
bio_cooked: { type: :string, nullable: true },
|
bio_cooked: { type: [:string, :null] },
|
||||||
bio_excerpt: { type: :string, nullable: true },
|
bio_excerpt: { type: [:string, :null] },
|
||||||
public_admission: { type: :boolean },
|
public_admission: { type: :boolean },
|
||||||
public_exit: { type: :boolean },
|
public_exit: { type: :boolean },
|
||||||
allow_membership_requests: { type: :boolean },
|
allow_membership_requests: { type: :boolean },
|
||||||
full_name: { type: :string, nullable: true },
|
full_name: { type: [:string, :null] },
|
||||||
default_notification_level: { type: :integer },
|
default_notification_level: { type: :integer },
|
||||||
membership_request_template: { type: :string, nullable: true },
|
membership_request_template: { type: [:string, :null] },
|
||||||
membership_visibility_level: { type: :integer },
|
membership_visibility_level: { type: :integer },
|
||||||
can_see_members: { type: :boolean },
|
can_see_members: { type: :boolean },
|
||||||
publish_read_state: { type: :boolean },
|
publish_read_state: { type: :boolean },
|
||||||
|
|
|
@ -20,8 +20,8 @@ describe 'invites' do
|
||||||
skip_email: { type: :boolean, default: false },
|
skip_email: { type: :boolean, default: false },
|
||||||
custom_message: { type: :string, description: "optional, for email invites" },
|
custom_message: { type: :string, description: "optional, for email invites" },
|
||||||
max_redemptions_allowed: { type: :integer, example: 5, default: 1, description: "optional, for link invites" },
|
max_redemptions_allowed: { type: :integer, example: 5, default: 1, description: "optional, for link invites" },
|
||||||
topic_id: { type: :int },
|
topic_id: { type: :integer },
|
||||||
group_id: { type: [:int], description: "optional, either this or `group_names`" },
|
group_id: { type: :integer, description: "optional, either this or `group_names`" },
|
||||||
group_names: { type: :string, description: "optional, either this or `group_id`" },
|
group_names: { type: :string, description: "optional, either this or `group_id`" },
|
||||||
expires_at: { type: :string, default: "controlled by invite_expiry_days site setting" },
|
expires_at: { type: :string, default: "controlled by invite_expiry_days site setting" },
|
||||||
}
|
}
|
||||||
|
@ -34,7 +34,7 @@ describe 'invites' do
|
||||||
link: { type: :string, example: "http://example.com/invites/9045fd767efe201ca60c6658bcf14158" },
|
link: { type: :string, example: "http://example.com/invites/9045fd767efe201ca60c6658bcf14158" },
|
||||||
email: { type: :string, example: "not-a-user-yet@example.com" },
|
email: { type: :string, example: "not-a-user-yet@example.com" },
|
||||||
emailed: { type: :boolean, example: false },
|
emailed: { type: :boolean, example: false },
|
||||||
custom_message: { type: :string, example: "Hello world!", nullable: true },
|
custom_message: { type: [:string, :null], example: "Hello world!" },
|
||||||
topics: { type: :array, example: [] },
|
topics: { type: :array, example: [] },
|
||||||
groups: { type: :array, example: [] },
|
groups: { type: :array, example: [] },
|
||||||
created_at: { type: :string, example: "2021-01-01T12:00:00.000Z" },
|
created_at: { type: :string, example: "2021-01-01T12:00:00.000Z" },
|
||||||
|
|
|
@ -29,9 +29,9 @@ describe 'notifications' do
|
||||||
notification_type: { type: :integer },
|
notification_type: { type: :integer },
|
||||||
read: { type: :boolean },
|
read: { type: :boolean },
|
||||||
created_at: { type: :string },
|
created_at: { type: :string },
|
||||||
post_number: { type: :string, nullable: true },
|
post_number: { type: [:string, :null] },
|
||||||
topic_id: { type: :integer, nullable: true },
|
topic_id: { type: [:integer, :null] },
|
||||||
slug: { type: :string, nullable: true },
|
slug: { type: [:string, :null] },
|
||||||
data: {
|
data: {
|
||||||
type: :object,
|
type: :object,
|
||||||
properties: {
|
properties: {
|
||||||
|
|
|
@ -37,7 +37,7 @@ describe 'posts' do
|
||||||
post_type: { type: :integer },
|
post_type: { type: :integer },
|
||||||
updated_at: { type: :string },
|
updated_at: { type: :string },
|
||||||
reply_count: { type: :integer },
|
reply_count: { type: :integer },
|
||||||
reply_to_post_number: { type: :string, nullable: true },
|
reply_to_post_number: { type: [:string, :null] },
|
||||||
quote_count: { type: :integer },
|
quote_count: { type: :integer },
|
||||||
incoming_link_count: { type: :integer },
|
incoming_link_count: { type: :integer },
|
||||||
reads: { type: :integer },
|
reads: { type: :integer },
|
||||||
|
@ -50,17 +50,17 @@ describe 'posts' do
|
||||||
topic_html_title: { type: :string },
|
topic_html_title: { type: :string },
|
||||||
category_id: { type: :integer },
|
category_id: { type: :integer },
|
||||||
display_username: { type: :string },
|
display_username: { type: :string },
|
||||||
primary_group_name: { type: :string, nullable: true },
|
primary_group_name: { type: [:string, :null] },
|
||||||
flair_name: { type: :string, nullable: true },
|
flair_name: { type: [:string, :null] },
|
||||||
flair_url: { type: :string, nullable: true },
|
flair_url: { type: [:string, :null] },
|
||||||
flair_bg_color: { type: :string, nullable: true },
|
flair_bg_color: { type: [:string, :null] },
|
||||||
flair_color: { type: :string, nullable: true },
|
flair_color: { type: [:string, :null] },
|
||||||
version: { type: :integer },
|
version: { type: :integer },
|
||||||
can_edit: { type: :boolean },
|
can_edit: { type: :boolean },
|
||||||
can_delete: { type: :boolean },
|
can_delete: { type: :boolean },
|
||||||
can_recover: { type: :boolean },
|
can_recover: { type: :boolean },
|
||||||
can_wiki: { type: :boolean },
|
can_wiki: { type: :boolean },
|
||||||
user_title: { type: :string, nullable: true },
|
user_title: { type: [:string, :null] },
|
||||||
raw: { type: :string },
|
raw: { type: :string },
|
||||||
actions_summary: {
|
actions_summary: {
|
||||||
type: :array,
|
type: :array,
|
||||||
|
@ -78,12 +78,12 @@ describe 'posts' do
|
||||||
user_id: { type: :integer },
|
user_id: { type: :integer },
|
||||||
hidden: { type: :boolean },
|
hidden: { type: :boolean },
|
||||||
trust_level: { type: :integer },
|
trust_level: { type: :integer },
|
||||||
deleted_at: { type: :string, nullable: true },
|
deleted_at: { type: [:string, :null] },
|
||||||
user_deleted: { type: :boolean },
|
user_deleted: { type: :boolean },
|
||||||
edit_reason: { type: :string, nullable: true },
|
edit_reason: { type: [:string, :null] },
|
||||||
can_view_edit_history: { type: :boolean },
|
can_view_edit_history: { type: :boolean },
|
||||||
wiki: { type: :boolean },
|
wiki: { type: :boolean },
|
||||||
reviewable_id: { type: :string, nullable: true },
|
reviewable_id: { type: [:string, :null] },
|
||||||
reviewable_score_count: { type: :integer },
|
reviewable_score_count: { type: :integer },
|
||||||
reviewable_score_pending_count: { type: :integer },
|
reviewable_score_pending_count: { type: :integer },
|
||||||
}
|
}
|
||||||
|
@ -130,7 +130,7 @@ describe 'posts' do
|
||||||
response '200', 'latest posts' do
|
response '200', 'latest posts' do
|
||||||
schema type: :object, properties: {
|
schema type: :object, properties: {
|
||||||
id: { type: :integer },
|
id: { type: :integer },
|
||||||
name: { type: :string, nullable: true },
|
name: { type: [:string, :null] },
|
||||||
username: { type: :string },
|
username: { type: :string },
|
||||||
avatar_template: { type: :string },
|
avatar_template: { type: :string },
|
||||||
created_at: { type: :string },
|
created_at: { type: :string },
|
||||||
|
@ -139,7 +139,7 @@ describe 'posts' do
|
||||||
post_type: { type: :integer },
|
post_type: { type: :integer },
|
||||||
updated_at: { type: :string },
|
updated_at: { type: :string },
|
||||||
reply_count: { type: :integer },
|
reply_count: { type: :integer },
|
||||||
reply_to_post_number: { type: :string, nullable: true },
|
reply_to_post_number: { type: [:string, :null] },
|
||||||
quote_count: { type: :integer },
|
quote_count: { type: :integer },
|
||||||
incoming_link_count: { type: :integer },
|
incoming_link_count: { type: :integer },
|
||||||
reads: { type: :integer },
|
reads: { type: :integer },
|
||||||
|
@ -148,18 +148,18 @@ describe 'posts' do
|
||||||
yours: { type: :boolean },
|
yours: { type: :boolean },
|
||||||
topic_id: { type: :integer },
|
topic_id: { type: :integer },
|
||||||
topic_slug: { type: :string },
|
topic_slug: { type: :string },
|
||||||
display_username: { type: :string, nullable: true },
|
display_username: { type: [:string, :null] },
|
||||||
primary_group_name: { type: :string, nullable: true },
|
primary_group_name: { type: [:string, :null] },
|
||||||
flair_name: { type: :string, nullable: true },
|
flair_name: { type: [:string, :null] },
|
||||||
flair_url: { type: :string, nullable: true },
|
flair_url: { type: [:string, :null] },
|
||||||
flair_bg_color: { type: :string, nullable: true },
|
flair_bg_color: { type: [:string, :null] },
|
||||||
flair_color: { type: :string, nullable: true },
|
flair_color: { type: [:string, :null] },
|
||||||
version: { type: :integer },
|
version: { type: :integer },
|
||||||
can_edit: { type: :boolean },
|
can_edit: { type: :boolean },
|
||||||
can_delete: { type: :boolean },
|
can_delete: { type: :boolean },
|
||||||
can_recover: { type: :boolean },
|
can_recover: { type: :boolean },
|
||||||
can_wiki: { type: :boolean },
|
can_wiki: { type: :boolean },
|
||||||
user_title: { type: :string, nullable: true },
|
user_title: { type: [:string, :null] },
|
||||||
raw: { type: :string },
|
raw: { type: :string },
|
||||||
actions_summary: {
|
actions_summary: {
|
||||||
type: :array,
|
type: :array,
|
||||||
|
@ -177,12 +177,12 @@ describe 'posts' do
|
||||||
user_id: { type: :integer },
|
user_id: { type: :integer },
|
||||||
hidden: { type: :boolean },
|
hidden: { type: :boolean },
|
||||||
trust_level: { type: :integer },
|
trust_level: { type: :integer },
|
||||||
deleted_at: { type: :string, nullable: true },
|
deleted_at: { type: [:string, :null] },
|
||||||
user_deleted: { type: :boolean },
|
user_deleted: { type: :boolean },
|
||||||
edit_reason: { type: :string, nullable: true },
|
edit_reason: { type: [:string, :null] },
|
||||||
can_view_edit_history: { type: :boolean },
|
can_view_edit_history: { type: :boolean },
|
||||||
wiki: { type: :boolean },
|
wiki: { type: :boolean },
|
||||||
reviewable_id: { type: :string, nullable: true },
|
reviewable_id: { type: [:string, :null] },
|
||||||
reviewable_score_count: { type: :integer },
|
reviewable_score_count: { type: :integer },
|
||||||
reviewable_score_pending_count: { type: :integer },
|
reviewable_score_pending_count: { type: :integer },
|
||||||
}
|
}
|
||||||
|
@ -219,7 +219,7 @@ describe 'posts' do
|
||||||
type: :object,
|
type: :object,
|
||||||
properties: {
|
properties: {
|
||||||
id: { type: :integer },
|
id: { type: :integer },
|
||||||
name: { type: :string, nullable: true },
|
name: { type: [:string, :null] },
|
||||||
username: { type: :string },
|
username: { type: :string },
|
||||||
avatar_template: { type: :string },
|
avatar_template: { type: :string },
|
||||||
created_at: { type: :string },
|
created_at: { type: :string },
|
||||||
|
@ -228,7 +228,7 @@ describe 'posts' do
|
||||||
post_type: { type: :integer },
|
post_type: { type: :integer },
|
||||||
updated_at: { type: :string },
|
updated_at: { type: :string },
|
||||||
reply_count: { type: :integer },
|
reply_count: { type: :integer },
|
||||||
reply_to_post_number: { type: :string, nullable: true },
|
reply_to_post_number: { type: [:string, :null] },
|
||||||
quote_count: { type: :integer },
|
quote_count: { type: :integer },
|
||||||
incoming_link_count: { type: :integer },
|
incoming_link_count: { type: :integer },
|
||||||
reads: { type: :integer },
|
reads: { type: :integer },
|
||||||
|
@ -237,17 +237,17 @@ describe 'posts' do
|
||||||
yours: { type: :boolean },
|
yours: { type: :boolean },
|
||||||
topic_id: { type: :integer },
|
topic_id: { type: :integer },
|
||||||
topic_slug: { type: :string },
|
topic_slug: { type: :string },
|
||||||
display_username: { type: :string, nullable: true },
|
display_username: { type: [:string, :null] },
|
||||||
primary_group_name: { type: :string, nullable: true },
|
primary_group_name: { type: [:string, :null] },
|
||||||
flair_url: { type: :string, nullable: true },
|
flair_url: { type: [:string, :null] },
|
||||||
flair_bg_color: { type: :string, nullable: true },
|
flair_bg_color: { type: [:string, :null] },
|
||||||
flair_color: { type: :string, nullable: true },
|
flair_color: { type: [:string, :null] },
|
||||||
version: { type: :integer },
|
version: { type: :integer },
|
||||||
can_edit: { type: :boolean },
|
can_edit: { type: :boolean },
|
||||||
can_delete: { type: :boolean },
|
can_delete: { type: :boolean },
|
||||||
can_recover: { type: :boolean },
|
can_recover: { type: :boolean },
|
||||||
can_wiki: { type: :boolean },
|
can_wiki: { type: :boolean },
|
||||||
user_title: { type: :string, nullable: true },
|
user_title: { type: [:string, :null] },
|
||||||
actions_summary: {
|
actions_summary: {
|
||||||
type: :array,
|
type: :array,
|
||||||
items: {
|
items: {
|
||||||
|
@ -265,12 +265,12 @@ describe 'posts' do
|
||||||
draft_sequence: { type: :integer },
|
draft_sequence: { type: :integer },
|
||||||
hidden: { type: :boolean },
|
hidden: { type: :boolean },
|
||||||
trust_level: { type: :integer },
|
trust_level: { type: :integer },
|
||||||
deleted_at: { type: :string, nullable: true },
|
deleted_at: { type: [:string, :null] },
|
||||||
user_deleted: { type: :boolean },
|
user_deleted: { type: :boolean },
|
||||||
edit_reason: { type: :string, nullable: true },
|
edit_reason: { type: [:string, :null] },
|
||||||
can_view_edit_history: { type: :boolean },
|
can_view_edit_history: { type: :boolean },
|
||||||
wiki: { type: :boolean },
|
wiki: { type: :boolean },
|
||||||
reviewable_id: { type: :string, nullable: true },
|
reviewable_id: { type: [:string, :null] },
|
||||||
reviewable_score_count: { type: :integer },
|
reviewable_score_count: { type: :integer },
|
||||||
reviewable_score_pending_count: { type: :integer },
|
reviewable_score_pending_count: { type: :integer },
|
||||||
}
|
}
|
||||||
|
@ -350,7 +350,7 @@ describe 'posts' do
|
||||||
post_type: { type: :integer },
|
post_type: { type: :integer },
|
||||||
updated_at: { type: :string },
|
updated_at: { type: :string },
|
||||||
reply_count: { type: :integer },
|
reply_count: { type: :integer },
|
||||||
reply_to_post_number: { type: :string, nullable: true },
|
reply_to_post_number: { type: [:string, :null] },
|
||||||
quote_count: { type: :integer },
|
quote_count: { type: :integer },
|
||||||
incoming_link_count: { type: :integer },
|
incoming_link_count: { type: :integer },
|
||||||
reads: { type: :integer },
|
reads: { type: :integer },
|
||||||
|
@ -360,17 +360,17 @@ describe 'posts' do
|
||||||
topic_id: { type: :integer },
|
topic_id: { type: :integer },
|
||||||
topic_slug: { type: :string },
|
topic_slug: { type: :string },
|
||||||
display_username: { type: :string },
|
display_username: { type: :string },
|
||||||
primary_group_name: { type: :string, nullable: true },
|
primary_group_name: { type: [:string, :null] },
|
||||||
flair_name: { type: :string, nullable: true },
|
flair_name: { type: [:string, :null] },
|
||||||
flair_url: { type: :string, nullable: true },
|
flair_url: { type: [:string, :null] },
|
||||||
flair_bg_color: { type: :string, nullable: true },
|
flair_bg_color: { type: [:string, :null] },
|
||||||
flair_color: { type: :string, nullable: true },
|
flair_color: { type: [:string, :null] },
|
||||||
version: { type: :integer },
|
version: { type: :integer },
|
||||||
can_edit: { type: :boolean },
|
can_edit: { type: :boolean },
|
||||||
can_delete: { type: :boolean },
|
can_delete: { type: :boolean },
|
||||||
can_recover: { type: :boolean },
|
can_recover: { type: :boolean },
|
||||||
can_wiki: { type: :boolean },
|
can_wiki: { type: :boolean },
|
||||||
user_title: { type: :string, nullable: true },
|
user_title: { type: [:string, :null] },
|
||||||
actions_summary: {
|
actions_summary: {
|
||||||
type: :array,
|
type: :array,
|
||||||
items: {
|
items: {
|
||||||
|
@ -389,13 +389,13 @@ describe 'posts' do
|
||||||
user_id: { type: :integer },
|
user_id: { type: :integer },
|
||||||
hidden: { type: :boolean },
|
hidden: { type: :boolean },
|
||||||
trust_level: { type: :integer },
|
trust_level: { type: :integer },
|
||||||
deleted_at: { type: :string, nullable: true },
|
deleted_at: { type: [:string, :null] },
|
||||||
user_deleted: { type: :boolean },
|
user_deleted: { type: :boolean },
|
||||||
edit_reason: { type: :string, nullable: true },
|
edit_reason: { type: [:string, :null] },
|
||||||
can_view_edit_history: { type: :boolean },
|
can_view_edit_history: { type: :boolean },
|
||||||
wiki: { type: :boolean },
|
wiki: { type: :boolean },
|
||||||
notice: { type: :object },
|
notice: { type: :object },
|
||||||
reviewable_id: { type: :string, nullable: true },
|
reviewable_id: { type: [:string, :null] },
|
||||||
reviewable_score_count: { type: :integer },
|
reviewable_score_count: { type: :integer },
|
||||||
reviewable_score_pending_count: { type: :integer },
|
reviewable_score_pending_count: { type: :integer },
|
||||||
}
|
}
|
||||||
|
|
|
@ -40,7 +40,7 @@ describe 'private messages' do
|
||||||
type: :object,
|
type: :object,
|
||||||
properties: {
|
properties: {
|
||||||
can_create_topic: { type: :boolean },
|
can_create_topic: { type: :boolean },
|
||||||
draft: { type: :string, nullable: true },
|
draft: { type: [:string, :null] },
|
||||||
draft_key: { type: :string },
|
draft_key: { type: :string },
|
||||||
draft_sequence: { type: :integer },
|
draft_sequence: { type: :integer },
|
||||||
per_page: { type: :integer },
|
per_page: { type: :integer },
|
||||||
|
@ -56,7 +56,7 @@ describe 'private messages' do
|
||||||
posts_count: { type: :integer },
|
posts_count: { type: :integer },
|
||||||
reply_count: { type: :integer },
|
reply_count: { type: :integer },
|
||||||
highest_post_number: { type: :integer },
|
highest_post_number: { type: :integer },
|
||||||
image_url: { type: :string, nullable: true },
|
image_url: { type: [:string, :null] },
|
||||||
created_at: { type: :string },
|
created_at: { type: :string },
|
||||||
last_posted_at: { type: :string },
|
last_posted_at: { type: :string },
|
||||||
bumped: { type: :boolean },
|
bumped: { type: :boolean },
|
||||||
|
@ -66,7 +66,7 @@ describe 'private messages' do
|
||||||
last_read_post_number: { type: :integer },
|
last_read_post_number: { type: :integer },
|
||||||
unread_posts: { type: :integer },
|
unread_posts: { type: :integer },
|
||||||
pinned: { type: :boolean },
|
pinned: { type: :boolean },
|
||||||
unpinned: { type: :string, nullable: true },
|
unpinned: { type: [:string, :null] },
|
||||||
visible: { type: :boolean },
|
visible: { type: :boolean },
|
||||||
closed: { type: :boolean },
|
closed: { type: :boolean },
|
||||||
archived: { type: :boolean },
|
archived: { type: :boolean },
|
||||||
|
@ -77,9 +77,9 @@ describe 'private messages' do
|
||||||
like_count: { type: :integer },
|
like_count: { type: :integer },
|
||||||
has_summary: { type: :boolean },
|
has_summary: { type: :boolean },
|
||||||
last_poster_username: { type: :string },
|
last_poster_username: { type: :string },
|
||||||
category_id: { type: :string, nullable: true },
|
category_id: { type: [:string, :null] },
|
||||||
pinned_globally: { type: :boolean },
|
pinned_globally: { type: :boolean },
|
||||||
featured_link: { type: :string, nullable: true },
|
featured_link: { type: [:string, :null] },
|
||||||
allowed_user_count: { type: :integer },
|
allowed_user_count: { type: :integer },
|
||||||
posters: {
|
posters: {
|
||||||
type: :array,
|
type: :array,
|
||||||
|
@ -89,7 +89,7 @@ describe 'private messages' do
|
||||||
extras: { type: :string },
|
extras: { type: :string },
|
||||||
description: { type: :string },
|
description: { type: :string },
|
||||||
user_id: { type: :integer },
|
user_id: { type: :integer },
|
||||||
primary_group_id: { type: :string, nullable: true },
|
primary_group_id: { type: [:string, :null] },
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
@ -99,9 +99,9 @@ describe 'private messages' do
|
||||||
type: :object,
|
type: :object,
|
||||||
properties: {
|
properties: {
|
||||||
extras: { type: :string },
|
extras: { type: :string },
|
||||||
description: { type: :string, nullable: true },
|
description: { type: [:string, :null] },
|
||||||
user_id: { type: :integer },
|
user_id: { type: :integer },
|
||||||
primary_group_id: { type: :string, nullable: true },
|
primary_group_id: { type: [:string, :null] },
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
@ -135,7 +135,7 @@ describe 'private messages' do
|
||||||
properties: {
|
properties: {
|
||||||
id: { type: :integer },
|
id: { type: :integer },
|
||||||
username: { type: :string },
|
username: { type: :string },
|
||||||
name: { type: :string, nullable: true },
|
name: { type: [:string, :null] },
|
||||||
avatar_template: { type: :string },
|
avatar_template: { type: :string },
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -149,7 +149,7 @@ describe 'private messages' do
|
||||||
type: :object,
|
type: :object,
|
||||||
properties: {
|
properties: {
|
||||||
can_create_topic: { type: :boolean },
|
can_create_topic: { type: :boolean },
|
||||||
draft: { type: :string, nullable: true },
|
draft: { type: [:string, :null] },
|
||||||
draft_key: { type: :string },
|
draft_key: { type: :string },
|
||||||
draft_sequence: { type: :integer },
|
draft_sequence: { type: :integer },
|
||||||
per_page: { type: :integer },
|
per_page: { type: :integer },
|
||||||
|
@ -165,7 +165,7 @@ describe 'private messages' do
|
||||||
posts_count: { type: :integer },
|
posts_count: { type: :integer },
|
||||||
reply_count: { type: :integer },
|
reply_count: { type: :integer },
|
||||||
highest_post_number: { type: :integer },
|
highest_post_number: { type: :integer },
|
||||||
image_url: { type: :string, nullable: true },
|
image_url: { type: [:string, :null] },
|
||||||
created_at: { type: :string },
|
created_at: { type: :string },
|
||||||
last_posted_at: { type: :string },
|
last_posted_at: { type: :string },
|
||||||
bumped: { type: :boolean },
|
bumped: { type: :boolean },
|
||||||
|
@ -175,7 +175,7 @@ describe 'private messages' do
|
||||||
last_read_post_number: { type: :integer },
|
last_read_post_number: { type: :integer },
|
||||||
unread_posts: { type: :integer },
|
unread_posts: { type: :integer },
|
||||||
pinned: { type: :boolean },
|
pinned: { type: :boolean },
|
||||||
unpinned: { type: :string, nullable: true },
|
unpinned: { type: [:string, :null] },
|
||||||
visible: { type: :boolean },
|
visible: { type: :boolean },
|
||||||
closed: { type: :boolean },
|
closed: { type: :boolean },
|
||||||
archived: { type: :boolean },
|
archived: { type: :boolean },
|
||||||
|
@ -186,9 +186,9 @@ describe 'private messages' do
|
||||||
like_count: { type: :integer },
|
like_count: { type: :integer },
|
||||||
has_summary: { type: :boolean },
|
has_summary: { type: :boolean },
|
||||||
last_poster_username: { type: :string },
|
last_poster_username: { type: :string },
|
||||||
category_id: { type: :string, nullable: true },
|
category_id: { type: [:string, :null] },
|
||||||
pinned_globally: { type: :boolean },
|
pinned_globally: { type: :boolean },
|
||||||
featured_link: { type: :string, nullable: true },
|
featured_link: { type: [:string, :null] },
|
||||||
allowed_user_count: { type: :integer },
|
allowed_user_count: { type: :integer },
|
||||||
posters: {
|
posters: {
|
||||||
type: :array,
|
type: :array,
|
||||||
|
@ -198,7 +198,7 @@ describe 'private messages' do
|
||||||
extras: { type: :string },
|
extras: { type: :string },
|
||||||
description: { type: :string },
|
description: { type: :string },
|
||||||
user_id: { type: :integer },
|
user_id: { type: :integer },
|
||||||
primary_group_id: { type: :string, nullable: true },
|
primary_group_id: { type: [:string, :null] },
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
|
@ -48,13 +48,13 @@
|
||||||
"type": "string"
|
"type": "string"
|
||||||
},
|
},
|
||||||
"last_seen_age": {
|
"last_seen_age": {
|
||||||
"type": ""
|
"type": ["number", "null"]
|
||||||
},
|
},
|
||||||
"last_emailed_age": {
|
"last_emailed_age": {
|
||||||
"type": ""
|
"type": ["number", "null"]
|
||||||
},
|
},
|
||||||
"created_at_age": {
|
"created_at_age": {
|
||||||
"type": ""
|
"type": ["number", "null"]
|
||||||
},
|
},
|
||||||
"trust_level": {
|
"trust_level": {
|
||||||
"type": "integer"
|
"type": "integer"
|
||||||
|
|
|
@ -39,13 +39,13 @@
|
||||||
"type": "string"
|
"type": "string"
|
||||||
},
|
},
|
||||||
"last_seen_age": {
|
"last_seen_age": {
|
||||||
"type": ""
|
"type": ["number", "null"]
|
||||||
},
|
},
|
||||||
"last_emailed_age": {
|
"last_emailed_age": {
|
||||||
"type": ""
|
"type": ["number", "null"]
|
||||||
},
|
},
|
||||||
"created_at_age": {
|
"created_at_age": {
|
||||||
"type": ""
|
"type": ["number", "null"]
|
||||||
},
|
},
|
||||||
"trust_level": {
|
"trust_level": {
|
||||||
"type": "integer"
|
"type": "integer"
|
||||||
|
@ -163,7 +163,7 @@
|
||||||
"type": "integer"
|
"type": "integer"
|
||||||
},
|
},
|
||||||
"bounce_score": {
|
"bounce_score": {
|
||||||
"type": ""
|
"type": ["integer", "null"]
|
||||||
},
|
},
|
||||||
"reset_bounce_score_after": {
|
"reset_bounce_score_after": {
|
||||||
"type": ["string", "null"]
|
"type": ["string", "null"]
|
||||||
|
|
|
@ -190,7 +190,7 @@ describe 'tags' do
|
||||||
text: { type: :string },
|
text: { type: :string },
|
||||||
count: { type: :integer },
|
count: { type: :integer },
|
||||||
pm_count: { type: :integer },
|
pm_count: { type: :integer },
|
||||||
target_tag: { type: :string, nullable: true },
|
target_tag: { type: [:string, :null] },
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
@ -227,7 +227,7 @@ describe 'tags' do
|
||||||
properties: {
|
properties: {
|
||||||
id: { type: :integer },
|
id: { type: :integer },
|
||||||
username: { type: :string },
|
username: { type: :string },
|
||||||
name: { type: :string, nullable: true },
|
name: { type: [:string, :null] },
|
||||||
avatar_template: { type: :string },
|
avatar_template: { type: :string },
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -241,7 +241,7 @@ describe 'tags' do
|
||||||
type: :object,
|
type: :object,
|
||||||
properties: {
|
properties: {
|
||||||
can_create_topic: { type: :boolean },
|
can_create_topic: { type: :boolean },
|
||||||
draft: { type: :string, nullable: true },
|
draft: { type: [:string, :null] },
|
||||||
draft_key: { type: :string },
|
draft_key: { type: :string },
|
||||||
draft_sequence: { type: :integer },
|
draft_sequence: { type: :integer },
|
||||||
per_page: { type: :integer },
|
per_page: { type: :integer },
|
||||||
|
@ -269,7 +269,7 @@ describe 'tags' do
|
||||||
posts_count: { type: :integer },
|
posts_count: { type: :integer },
|
||||||
reply_count: { type: :integer },
|
reply_count: { type: :integer },
|
||||||
highest_post_number: { type: :integer },
|
highest_post_number: { type: :integer },
|
||||||
image_url: { type: :string, nullable: true },
|
image_url: { type: [:string, :null] },
|
||||||
created_at: { type: :string },
|
created_at: { type: :string },
|
||||||
last_posted_at: { type: :string },
|
last_posted_at: { type: :string },
|
||||||
bumped: { type: :boolean },
|
bumped: { type: :boolean },
|
||||||
|
@ -279,7 +279,7 @@ describe 'tags' do
|
||||||
last_read_post_number: { type: :integer },
|
last_read_post_number: { type: :integer },
|
||||||
unread_posts: { type: :integer },
|
unread_posts: { type: :integer },
|
||||||
pinned: { type: :boolean },
|
pinned: { type: :boolean },
|
||||||
unpinned: { type: :string, nullable: true },
|
unpinned: { type: [:string, :null] },
|
||||||
visible: { type: :boolean },
|
visible: { type: :boolean },
|
||||||
closed: { type: :boolean },
|
closed: { type: :boolean },
|
||||||
archived: { type: :boolean },
|
archived: { type: :boolean },
|
||||||
|
@ -297,7 +297,7 @@ describe 'tags' do
|
||||||
last_poster_username: { type: :string },
|
last_poster_username: { type: :string },
|
||||||
category_id: { type: :integer },
|
category_id: { type: :integer },
|
||||||
pinned_globally: { type: :boolean },
|
pinned_globally: { type: :boolean },
|
||||||
featured_link: { type: :string, nullable: true },
|
featured_link: { type: [:string, :null] },
|
||||||
posters: {
|
posters: {
|
||||||
type: :array,
|
type: :array,
|
||||||
items: {
|
items: {
|
||||||
|
@ -306,7 +306,7 @@ describe 'tags' do
|
||||||
extras: { type: :string },
|
extras: { type: :string },
|
||||||
description: { type: :string },
|
description: { type: :string },
|
||||||
user_id: { type: :integer },
|
user_id: { type: :integer },
|
||||||
primary_group_id: { type: :string, nullable: true },
|
primary_group_id: { type: [:string, :null] },
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
|
@ -33,7 +33,7 @@ describe 'topics' do
|
||||||
type: :object,
|
type: :object,
|
||||||
properties: {
|
properties: {
|
||||||
id: { type: :integer },
|
id: { type: :integer },
|
||||||
name: { type: :string, nullable: true },
|
name: { type: [:string, :null] },
|
||||||
username: { type: :string },
|
username: { type: :string },
|
||||||
avatar_template: { type: :string },
|
avatar_template: { type: :string },
|
||||||
created_at: { type: :string },
|
created_at: { type: :string },
|
||||||
|
@ -42,7 +42,7 @@ describe 'topics' do
|
||||||
post_type: { type: :integer },
|
post_type: { type: :integer },
|
||||||
updated_at: { type: :string },
|
updated_at: { type: :string },
|
||||||
reply_count: { type: :integer },
|
reply_count: { type: :integer },
|
||||||
reply_to_post_number: { type: :string, nullable: true },
|
reply_to_post_number: { type: [:string, :null] },
|
||||||
quote_count: { type: :integer },
|
quote_count: { type: :integer },
|
||||||
incoming_link_count: { type: :integer },
|
incoming_link_count: { type: :integer },
|
||||||
reads: { type: :integer },
|
reads: { type: :integer },
|
||||||
|
@ -51,19 +51,19 @@ describe 'topics' do
|
||||||
yours: { type: :boolean },
|
yours: { type: :boolean },
|
||||||
topic_id: { type: :integer },
|
topic_id: { type: :integer },
|
||||||
topic_slug: { type: :string },
|
topic_slug: { type: :string },
|
||||||
display_username: { type: :string, nullable: true },
|
display_username: { type: [:string, :null] },
|
||||||
primary_group_name: { type: :string, nullable: true },
|
primary_group_name: { type: [:string, :null] },
|
||||||
flair_name: { type: :string, nullable: true },
|
flair_name: { type: [:string, :null] },
|
||||||
flair_url: { type: :string, nullable: true },
|
flair_url: { type: [:string, :null] },
|
||||||
flair_bg_color: { type: :string, nullable: true },
|
flair_bg_color: { type: [:string, :null] },
|
||||||
flair_color: { type: :string, nullable: true },
|
flair_color: { type: [:string, :null] },
|
||||||
version: { type: :integer },
|
version: { type: :integer },
|
||||||
can_edit: { type: :boolean },
|
can_edit: { type: :boolean },
|
||||||
can_delete: { type: :boolean },
|
can_delete: { type: :boolean },
|
||||||
can_recover: { type: :boolean },
|
can_recover: { type: :boolean },
|
||||||
can_wiki: { type: :boolean },
|
can_wiki: { type: :boolean },
|
||||||
read: { type: :boolean },
|
read: { type: :boolean },
|
||||||
user_title: { type: :string, nullable: true },
|
user_title: { type: [:string, :null] },
|
||||||
actions_summary: {
|
actions_summary: {
|
||||||
type: :array,
|
type: :array,
|
||||||
items: {
|
items: {
|
||||||
|
@ -80,9 +80,9 @@ describe 'topics' do
|
||||||
user_id: { type: :integer },
|
user_id: { type: :integer },
|
||||||
hidden: { type: :boolean },
|
hidden: { type: :boolean },
|
||||||
trust_level: { type: :integer },
|
trust_level: { type: :integer },
|
||||||
deleted_at: { type: :string, nullable: true },
|
deleted_at: { type: [:string, :null] },
|
||||||
user_deleted: { type: :boolean },
|
user_deleted: { type: :boolean },
|
||||||
edit_reason: { type: :string, nullable: true },
|
edit_reason: { type: [:string, :null] },
|
||||||
can_view_edit_history: { type: :boolean },
|
can_view_edit_history: { type: :boolean },
|
||||||
wiki: { type: :boolean },
|
wiki: { type: :boolean },
|
||||||
reviewable_id: { type: :integer },
|
reviewable_id: { type: :integer },
|
||||||
|
@ -134,7 +134,7 @@ describe 'topics' do
|
||||||
post_type: { type: :integer },
|
post_type: { type: :integer },
|
||||||
updated_at: { type: :string },
|
updated_at: { type: :string },
|
||||||
reply_count: { type: :integer },
|
reply_count: { type: :integer },
|
||||||
reply_to_post_number: { type: :string, nullable: true },
|
reply_to_post_number: { type: [:string, :null] },
|
||||||
quote_count: { type: :integer },
|
quote_count: { type: :integer },
|
||||||
incoming_link_count: { type: :integer },
|
incoming_link_count: { type: :integer },
|
||||||
reads: { type: :integer },
|
reads: { type: :integer },
|
||||||
|
@ -144,11 +144,11 @@ describe 'topics' do
|
||||||
topic_id: { type: :integer },
|
topic_id: { type: :integer },
|
||||||
topic_slug: { type: :string },
|
topic_slug: { type: :string },
|
||||||
display_username: { type: :string },
|
display_username: { type: :string },
|
||||||
primary_group_name: { type: :string, nullable: true },
|
primary_group_name: { type: [:string, :null] },
|
||||||
flair_name: { type: :string, nullable: true },
|
flair_name: { type: [:string, :null] },
|
||||||
flair_url: { type: :string, nullable: true },
|
flair_url: { type: [:string, :null] },
|
||||||
flair_bg_color: { type: :string, nullable: true },
|
flair_bg_color: { type: [:string, :null] },
|
||||||
flair_color: { type: :string, nullable: true },
|
flair_color: { type: [:string, :null] },
|
||||||
version: { type: :integer },
|
version: { type: :integer },
|
||||||
can_edit: { type: :boolean },
|
can_edit: { type: :boolean },
|
||||||
can_delete: { type: :boolean },
|
can_delete: { type: :boolean },
|
||||||
|
@ -167,7 +167,7 @@ describe 'topics' do
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
read: { type: :boolean },
|
read: { type: :boolean },
|
||||||
user_title: { type: :string, nullable: true },
|
user_title: { type: [:string, :null] },
|
||||||
actions_summary: {
|
actions_summary: {
|
||||||
type: :array,
|
type: :array,
|
||||||
items: {
|
items: {
|
||||||
|
@ -184,9 +184,9 @@ describe 'topics' do
|
||||||
user_id: { type: :integer },
|
user_id: { type: :integer },
|
||||||
hidden: { type: :boolean },
|
hidden: { type: :boolean },
|
||||||
trust_level: { type: :integer },
|
trust_level: { type: :integer },
|
||||||
deleted_at: { type: :string, nullable: true },
|
deleted_at: { type: [:string, :null] },
|
||||||
user_deleted: { type: :boolean },
|
user_deleted: { type: :boolean },
|
||||||
edit_reason: { type: :string, nullable: true },
|
edit_reason: { type: [:string, :null] },
|
||||||
can_view_edit_history: { type: :boolean },
|
can_view_edit_history: { type: :boolean },
|
||||||
wiki: { type: :boolean },
|
wiki: { type: :boolean },
|
||||||
reviewable_id: { type: :integer },
|
reviewable_id: { type: :integer },
|
||||||
|
@ -219,9 +219,9 @@ describe 'topics' do
|
||||||
posts_count: { type: :integer },
|
posts_count: { type: :integer },
|
||||||
reply_count: { type: :integer },
|
reply_count: { type: :integer },
|
||||||
highest_post_number: { type: :integer },
|
highest_post_number: { type: :integer },
|
||||||
image_url: { type: :string, nullable: true },
|
image_url: { type: [:string, :null] },
|
||||||
created_at: { type: :string },
|
created_at: { type: :string },
|
||||||
last_posted_at: { type: :string, nullable: true },
|
last_posted_at: { type: [:string, :null] },
|
||||||
bumped: { type: :boolean },
|
bumped: { type: :boolean },
|
||||||
bumped_at: { type: :string },
|
bumped_at: { type: :string },
|
||||||
archetype: { type: :string },
|
archetype: { type: :string },
|
||||||
|
@ -239,13 +239,13 @@ describe 'topics' do
|
||||||
like_count: { type: :integer },
|
like_count: { type: :integer },
|
||||||
views: { type: :integer },
|
views: { type: :integer },
|
||||||
category_id: { type: :integer },
|
category_id: { type: :integer },
|
||||||
featured_link: { type: :string, nullable: true },
|
featured_link: { type: [:string, :null] },
|
||||||
posters: {
|
posters: {
|
||||||
type: :array,
|
type: :array,
|
||||||
items: {
|
items: {
|
||||||
type: :object,
|
type: :object,
|
||||||
properties: {
|
properties: {
|
||||||
extras: { type: :string, nullable: true },
|
extras: { type: [:string, :null] },
|
||||||
description: { type: :string },
|
description: { type: :string },
|
||||||
user: {
|
user: {
|
||||||
type: :object,
|
type: :object,
|
||||||
|
@ -270,7 +270,7 @@ describe 'topics' do
|
||||||
views: { type: :integer },
|
views: { type: :integer },
|
||||||
reply_count: { type: :integer },
|
reply_count: { type: :integer },
|
||||||
like_count: { type: :integer },
|
like_count: { type: :integer },
|
||||||
last_posted_at: { type: :string, nullable: true },
|
last_posted_at: { type: [:string, :null] },
|
||||||
visible: { type: :boolean },
|
visible: { type: :boolean },
|
||||||
closed: { type: :boolean },
|
closed: { type: :boolean },
|
||||||
archived: { type: :boolean },
|
archived: { type: :boolean },
|
||||||
|
@ -278,22 +278,22 @@ describe 'topics' do
|
||||||
archetype: { type: :string },
|
archetype: { type: :string },
|
||||||
slug: { type: :string },
|
slug: { type: :string },
|
||||||
category_id: { type: :integer },
|
category_id: { type: :integer },
|
||||||
word_count: { type: :integer, nullable: true },
|
word_count: { type: [:integer, :null] },
|
||||||
deleted_at: { type: :string, nullable: true },
|
deleted_at: { type: [:string, :null] },
|
||||||
user_id: { type: :integer },
|
user_id: { type: :integer },
|
||||||
featured_link: { type: :string, nullable: true },
|
featured_link: { type: [:string, :null] },
|
||||||
pinned_globally: { type: :boolean },
|
pinned_globally: { type: :boolean },
|
||||||
pinned_at: { type: :string, nullable: true },
|
pinned_at: { type: [:string, :null] },
|
||||||
pinned_until: { type: :string, nullable: true },
|
pinned_until: { type: [:string, :null] },
|
||||||
image_url: { type: :string, nullable: true },
|
image_url: { type: [:string, :null] },
|
||||||
draft: { type: :string, nullable: true },
|
draft: { type: [:string, :null] },
|
||||||
draft_key: { type: :string },
|
draft_key: { type: :string },
|
||||||
draft_sequence: { type: :integer },
|
draft_sequence: { type: :integer },
|
||||||
unpinned: { type: :string, nullable: true },
|
unpinned: { type: [:string, :null] },
|
||||||
pinned: { type: :boolean },
|
pinned: { type: :boolean },
|
||||||
current_post_number: { type: :integer },
|
current_post_number: { type: :integer },
|
||||||
highest_post_number: { type: :integer, nullable: true },
|
highest_post_number: { type: [:integer, :null] },
|
||||||
deleted_by: { type: :string, nullable: true },
|
deleted_by: { type: [:string, :null] },
|
||||||
has_deleted: { type: :boolean },
|
has_deleted: { type: :boolean },
|
||||||
actions_summary: {
|
actions_summary: {
|
||||||
type: :array,
|
type: :array,
|
||||||
|
@ -309,11 +309,11 @@ describe 'topics' do
|
||||||
},
|
},
|
||||||
chunk_size: { type: :integer },
|
chunk_size: { type: :integer },
|
||||||
bookmarked: { type: :boolean },
|
bookmarked: { type: :boolean },
|
||||||
topic_timer: { type: :string, nullable: true },
|
topic_timer: { type: [:string, :null] },
|
||||||
message_bus_last_id: { type: :integer },
|
message_bus_last_id: { type: :integer },
|
||||||
participant_count: { type: :integer },
|
participant_count: { type: :integer },
|
||||||
show_read_indicator: { type: :boolean },
|
show_read_indicator: { type: :boolean },
|
||||||
thumbnails: { type: :string, nullable: true },
|
thumbnails: { type: [:string, :null] },
|
||||||
details: {
|
details: {
|
||||||
type: :object,
|
type: :object,
|
||||||
properties: {
|
properties: {
|
||||||
|
@ -338,11 +338,11 @@ describe 'topics' do
|
||||||
name: { type: :string },
|
name: { type: :string },
|
||||||
avatar_template: { type: :string },
|
avatar_template: { type: :string },
|
||||||
post_count: { type: :integer },
|
post_count: { type: :integer },
|
||||||
primary_group_name: { type: :string, nullable: true },
|
primary_group_name: { type: [:string, :null] },
|
||||||
flair_name: { type: :string, nullable: true },
|
flair_name: { type: [:string, :null] },
|
||||||
flair_url: { type: :string, nullable: true },
|
flair_url: { type: [:string, :null] },
|
||||||
flair_color: { type: :string, nullable: true },
|
flair_color: { type: [:string, :null] },
|
||||||
flair_bg_color: { type: :string, nullable: true },
|
flair_bg_color: { type: [:string, :null] },
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
@ -529,7 +529,7 @@ describe 'topics' do
|
||||||
response '200', 'topic updated' do
|
response '200', 'topic updated' do
|
||||||
schema type: :object, properties: {
|
schema type: :object, properties: {
|
||||||
success: { type: :string, example: "OK" },
|
success: { type: :string, example: "OK" },
|
||||||
topic_status_update: { type: :string, nullable: true },
|
topic_status_update: { type: [:string, :null] },
|
||||||
}
|
}
|
||||||
|
|
||||||
let(:request_body) { { status: 'closed', enabled: 'true' } }
|
let(:request_body) { { status: 'closed', enabled: 'true' } }
|
||||||
|
@ -567,7 +567,7 @@ describe 'topics' do
|
||||||
properties: {
|
properties: {
|
||||||
id: { type: :integer },
|
id: { type: :integer },
|
||||||
username: { type: :string },
|
username: { type: :string },
|
||||||
name: { type: :string, nullable: true },
|
name: { type: [:string, :null] },
|
||||||
avatar_template: { type: :string },
|
avatar_template: { type: :string },
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -581,7 +581,7 @@ describe 'topics' do
|
||||||
type: :object,
|
type: :object,
|
||||||
properties: {
|
properties: {
|
||||||
can_create_topic: { type: :boolean },
|
can_create_topic: { type: :boolean },
|
||||||
draft: { type: :string, nullable: true },
|
draft: { type: [:string, :null] },
|
||||||
draft_key: { type: :string },
|
draft_key: { type: :string },
|
||||||
draft_sequence: { type: :integer },
|
draft_sequence: { type: :integer },
|
||||||
per_page: { type: :integer },
|
per_page: { type: :integer },
|
||||||
|
@ -607,7 +607,7 @@ describe 'topics' do
|
||||||
last_read_post_number: { type: :integer },
|
last_read_post_number: { type: :integer },
|
||||||
unread_posts: { type: :integer },
|
unread_posts: { type: :integer },
|
||||||
pinned: { type: :boolean },
|
pinned: { type: :boolean },
|
||||||
unpinned: { type: :string, nullable: true },
|
unpinned: { type: [:string, :null] },
|
||||||
visible: { type: :boolean },
|
visible: { type: :boolean },
|
||||||
closed: { type: :boolean },
|
closed: { type: :boolean },
|
||||||
archived: { type: :boolean },
|
archived: { type: :boolean },
|
||||||
|
@ -621,7 +621,7 @@ describe 'topics' do
|
||||||
category_id: { type: :integer },
|
category_id: { type: :integer },
|
||||||
op_like_count: { type: :integer },
|
op_like_count: { type: :integer },
|
||||||
pinned_globally: { type: :boolean },
|
pinned_globally: { type: :boolean },
|
||||||
featured_link: { type: :string, nullable: true },
|
featured_link: { type: [:string, :null] },
|
||||||
posters: {
|
posters: {
|
||||||
type: :array,
|
type: :array,
|
||||||
items: {
|
items: {
|
||||||
|
@ -630,7 +630,7 @@ describe 'topics' do
|
||||||
extras: { type: :string },
|
extras: { type: :string },
|
||||||
description: { type: :string },
|
description: { type: :string },
|
||||||
user_id: { type: :integer },
|
user_id: { type: :integer },
|
||||||
primary_group_id: { type: :string, nullable: true },
|
primary_group_id: { type: [:string, :null] },
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
@ -680,7 +680,7 @@ describe 'topics' do
|
||||||
type: :object,
|
type: :object,
|
||||||
properties: {
|
properties: {
|
||||||
can_create_topic: { type: :boolean },
|
can_create_topic: { type: :boolean },
|
||||||
draft: { type: :string, nullable: true },
|
draft: { type: [:string, :null] },
|
||||||
draft_key: { type: :string },
|
draft_key: { type: :string },
|
||||||
draft_sequence: { type: :integer },
|
draft_sequence: { type: :integer },
|
||||||
for_period: { type: :string },
|
for_period: { type: :string },
|
||||||
|
@ -697,7 +697,7 @@ describe 'topics' do
|
||||||
posts_count: { type: :integer },
|
posts_count: { type: :integer },
|
||||||
reply_count: { type: :integer },
|
reply_count: { type: :integer },
|
||||||
highest_post_number: { type: :integer },
|
highest_post_number: { type: :integer },
|
||||||
image_url: { type: :string, nullable: true },
|
image_url: { type: [:string, :null] },
|
||||||
created_at: { type: :string },
|
created_at: { type: :string },
|
||||||
last_posted_at: { type: :string },
|
last_posted_at: { type: :string },
|
||||||
bumped: { type: :boolean },
|
bumped: { type: :boolean },
|
||||||
|
@ -721,16 +721,16 @@ describe 'topics' do
|
||||||
category_id: { type: :integer },
|
category_id: { type: :integer },
|
||||||
op_like_count: { type: :integer },
|
op_like_count: { type: :integer },
|
||||||
pinned_globally: { type: :boolean },
|
pinned_globally: { type: :boolean },
|
||||||
featured_link: { type: :string, nullable: true },
|
featured_link: { type: [:string, :null] },
|
||||||
posters: {
|
posters: {
|
||||||
type: :array,
|
type: :array,
|
||||||
items: {
|
items: {
|
||||||
type: :object,
|
type: :object,
|
||||||
properties: {
|
properties: {
|
||||||
extras: { type: :string, nullable: true },
|
extras: { type: [:string, :null] },
|
||||||
description: { type: :string },
|
description: { type: :string },
|
||||||
user_id: { type: :integer },
|
user_id: { type: :integer },
|
||||||
primary_group_id: { type: :string, nullable: true },
|
primary_group_id: { type: [:string, :null] },
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
@ -782,7 +782,7 @@ describe 'topics' do
|
||||||
type: :object,
|
type: :object,
|
||||||
properties: {
|
properties: {
|
||||||
can_create_topic: { type: :boolean },
|
can_create_topic: { type: :boolean },
|
||||||
draft: { type: :string, nullable: true },
|
draft: { type: [:string, :null] },
|
||||||
draft_key: { type: :string },
|
draft_key: { type: :string },
|
||||||
draft_sequence: { type: :integer },
|
draft_sequence: { type: :integer },
|
||||||
for_period: { type: :string },
|
for_period: { type: :string },
|
||||||
|
@ -799,7 +799,7 @@ describe 'topics' do
|
||||||
posts_count: { type: :integer },
|
posts_count: { type: :integer },
|
||||||
reply_count: { type: :integer },
|
reply_count: { type: :integer },
|
||||||
highest_post_number: { type: :integer },
|
highest_post_number: { type: :integer },
|
||||||
image_url: { type: :string, nullable: true },
|
image_url: { type: [:string, :null] },
|
||||||
created_at: { type: :string },
|
created_at: { type: :string },
|
||||||
last_posted_at: { type: :string },
|
last_posted_at: { type: :string },
|
||||||
bumped: { type: :boolean },
|
bumped: { type: :boolean },
|
||||||
|
@ -823,16 +823,16 @@ describe 'topics' do
|
||||||
category_id: { type: :integer },
|
category_id: { type: :integer },
|
||||||
op_like_count: { type: :integer },
|
op_like_count: { type: :integer },
|
||||||
pinned_globally: { type: :boolean },
|
pinned_globally: { type: :boolean },
|
||||||
featured_link: { type: :string, nullable: true },
|
featured_link: { type: [:string, :null] },
|
||||||
posters: {
|
posters: {
|
||||||
type: :array,
|
type: :array,
|
||||||
items: {
|
items: {
|
||||||
type: :object,
|
type: :object,
|
||||||
properties: {
|
properties: {
|
||||||
extras: { type: :string, nullable: true },
|
extras: { type: [:string, :null] },
|
||||||
description: { type: :string },
|
description: { type: :string },
|
||||||
user_id: { type: :integer },
|
user_id: { type: :integer },
|
||||||
primary_group_id: { type: :string, nullable: true },
|
primary_group_id: { type: [:string, :null] },
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
@ -947,10 +947,10 @@ describe 'topics' do
|
||||||
schema type: :object, properties: {
|
schema type: :object, properties: {
|
||||||
success: { type: :string, example: "OK" },
|
success: { type: :string, example: "OK" },
|
||||||
execute_at: { type: :string },
|
execute_at: { type: :string },
|
||||||
duration: { type: :string, nullable: true },
|
duration: { type: [:string, :null] },
|
||||||
based_on_last_post: { type: :boolean },
|
based_on_last_post: { type: :boolean },
|
||||||
closed: { type: :boolean },
|
closed: { type: :boolean },
|
||||||
category_id: { type: :string, nullable: true },
|
category_id: { type: [:string, :null] },
|
||||||
}
|
}
|
||||||
|
|
||||||
let(:request_body) { { time: Time.current + 1.day, status_type: 'close' } }
|
let(:request_body) { { time: Time.current + 1.day, status_type: 'close' } }
|
||||||
|
|
|
@ -125,8 +125,8 @@ RSpec.configure do |config|
|
||||||
username: { type: :string },
|
username: { type: :string },
|
||||||
name: { type: :string },
|
name: { type: :string },
|
||||||
avatar_template: { type: :string },
|
avatar_template: { type: :string },
|
||||||
last_posted_at: { type: :string, nullable: true },
|
last_posted_at: { type: [:string, :null] },
|
||||||
last_seen_at: { type: :string, nullable: true },
|
last_seen_at: { type: [:string, :null] },
|
||||||
created_at: { type: :string },
|
created_at: { type: :string },
|
||||||
ignored: { type: :boolean },
|
ignored: { type: :boolean },
|
||||||
muted: { type: :boolean },
|
muted: { type: :boolean },
|
||||||
|
@ -137,7 +137,7 @@ RSpec.configure do |config|
|
||||||
trust_level: { type: :integer },
|
trust_level: { type: :integer },
|
||||||
moderator: { type: :boolean },
|
moderator: { type: :boolean },
|
||||||
admin: { type: :boolean },
|
admin: { type: :boolean },
|
||||||
title: { type: :string, nullable: true },
|
title: { type: [:string, :null] },
|
||||||
badge_count: { type: :integer },
|
badge_count: { type: :integer },
|
||||||
user_fields: {
|
user_fields: {
|
||||||
type: :object,
|
type: :object,
|
||||||
|
@ -151,18 +151,18 @@ RSpec.configure do |config|
|
||||||
},
|
},
|
||||||
time_read: { type: :integer },
|
time_read: { type: :integer },
|
||||||
recent_time_read: { type: :integer },
|
recent_time_read: { type: :integer },
|
||||||
primary_group_id: { type: :string, nullable: true },
|
primary_group_id: { type: [:string, :null] },
|
||||||
primary_group_name: { type: :string, nullable: true },
|
primary_group_name: { type: [:string, :null] },
|
||||||
flair_url: { type: :string, nullable: true },
|
flair_url: { type: [:string, :null] },
|
||||||
flair_bg_color: { type: :string, nullable: true },
|
flair_bg_color: { type: [:string, :null] },
|
||||||
flair_color: { type: :string, nullable: true },
|
flair_color: { type: [:string, :null] },
|
||||||
featured_topic: { type: :string, nullable: true },
|
featured_topic: { type: [:string, :null] },
|
||||||
staged: { type: :boolean },
|
staged: { type: :boolean },
|
||||||
can_edit: { type: :boolean },
|
can_edit: { type: :boolean },
|
||||||
can_edit_username: { type: :boolean },
|
can_edit_username: { type: :boolean },
|
||||||
can_edit_email: { type: :boolean },
|
can_edit_email: { type: :boolean },
|
||||||
can_edit_name: { type: :boolean },
|
can_edit_name: { type: :boolean },
|
||||||
uploaded_avatar_id: { type: :string, nullable: true },
|
uploaded_avatar_id: { type: [:string, :null] },
|
||||||
has_title_badges: { type: :boolean },
|
has_title_badges: { type: :boolean },
|
||||||
pending_count: { type: :integer },
|
pending_count: { type: :integer },
|
||||||
profile_view_count: { type: :integer },
|
profile_view_count: { type: :integer },
|
||||||
|
@ -172,7 +172,7 @@ RSpec.configure do |config|
|
||||||
post_count: { type: :integer },
|
post_count: { type: :integer },
|
||||||
can_be_deleted: { type: :boolean },
|
can_be_deleted: { type: :boolean },
|
||||||
can_delete_all_posts: { type: :boolean },
|
can_delete_all_posts: { type: :boolean },
|
||||||
locale: { type: :string, nullable: true },
|
locale: { type: [:string, :null] },
|
||||||
muted_category_ids: {
|
muted_category_ids: {
|
||||||
type: :array,
|
type: :array,
|
||||||
items: {
|
items: {
|
||||||
|
@ -218,7 +218,7 @@ RSpec.configure do |config|
|
||||||
items: {
|
items: {
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
system_avatar_upload_id: { type: :string, nullable: true },
|
system_avatar_upload_id: { type: [:string, :null] },
|
||||||
system_avatar_template: { type: :string },
|
system_avatar_template: { type: :string },
|
||||||
muted_usernames: {
|
muted_usernames: {
|
||||||
type: :array,
|
type: :array,
|
||||||
|
@ -239,7 +239,7 @@ RSpec.configure do |config|
|
||||||
can_change_bio: { type: :boolean },
|
can_change_bio: { type: :boolean },
|
||||||
can_change_location: { type: :boolean },
|
can_change_location: { type: :boolean },
|
||||||
can_change_website: { type: :boolean },
|
can_change_website: { type: :boolean },
|
||||||
user_api_keys: { type: :string, nullable: true },
|
user_api_keys: { type: [:string, :null] },
|
||||||
user_auth_tokens: {
|
user_auth_tokens: {
|
||||||
type: :array,
|
type: :array,
|
||||||
items: {
|
items: {
|
||||||
|
@ -263,7 +263,7 @@ RSpec.configure do |config|
|
||||||
items: {
|
items: {
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
invited_by: { type: :string, nullable: true },
|
invited_by: { type: [:string, :null] },
|
||||||
groups: {
|
groups: {
|
||||||
type: :array,
|
type: :array,
|
||||||
items: {
|
items: {
|
||||||
|
@ -278,22 +278,22 @@ RSpec.configure do |config|
|
||||||
messageable_level: { type: :integer },
|
messageable_level: { type: :integer },
|
||||||
visibility_level: { type: :integer },
|
visibility_level: { type: :integer },
|
||||||
primary_group: { type: :boolean },
|
primary_group: { type: :boolean },
|
||||||
title: { type: :string, nullable: true },
|
title: { type: [:string, :null] },
|
||||||
grant_trust_level: { type: :string, nullable: true },
|
grant_trust_level: { type: [:string, :null] },
|
||||||
incoming_email: { type: :string, nullable: true },
|
incoming_email: { type: [:string, :null] },
|
||||||
has_messages: { type: :boolean },
|
has_messages: { type: :boolean },
|
||||||
flair_url: { type: :string, nullable: true },
|
flair_url: { type: [:string, :null] },
|
||||||
flair_bg_color: { type: :string, nullable: true },
|
flair_bg_color: { type: [:string, :null] },
|
||||||
flair_color: { type: :string, nullable: true },
|
flair_color: { type: [:string, :null] },
|
||||||
bio_raw: { type: :string, nullable: true },
|
bio_raw: { type: [:string, :null] },
|
||||||
bio_cooked: { type: :string, nullable: true },
|
bio_cooked: { type: [:string, :null] },
|
||||||
bio_excerpt: { type: :string, nullable: true },
|
bio_excerpt: { type: [:string, :null] },
|
||||||
public_admission: { type: :boolean },
|
public_admission: { type: :boolean },
|
||||||
public_exit: { type: :boolean },
|
public_exit: { type: :boolean },
|
||||||
allow_membership_requests: { type: :boolean },
|
allow_membership_requests: { type: :boolean },
|
||||||
full_name: { type: :string, nullable: true },
|
full_name: { type: [:string, :null] },
|
||||||
default_notification_level: { type: :integer },
|
default_notification_level: { type: :integer },
|
||||||
membership_request_template: { type: :string, nullable: true },
|
membership_request_template: { type: [:string, :null] },
|
||||||
members_visibility_level: { type: :integer },
|
members_visibility_level: { type: :integer },
|
||||||
can_see_members: { type: :boolean },
|
can_see_members: { type: :boolean },
|
||||||
can_admin_group: { type: :boolean },
|
can_admin_group: { type: :boolean },
|
||||||
|
@ -322,8 +322,8 @@ RSpec.configure do |config|
|
||||||
email_level: { type: :integer },
|
email_level: { type: :integer },
|
||||||
email_messages_level: { type: :integer },
|
email_messages_level: { type: :integer },
|
||||||
external_links_in_new_tab: { type: :boolean },
|
external_links_in_new_tab: { type: :boolean },
|
||||||
color_scheme_id: { type: :string, nullable: true },
|
color_scheme_id: { type: [:string, :null] },
|
||||||
dark_scheme_id: { type: :string, nullable: true },
|
dark_scheme_id: { type: [:string, :null] },
|
||||||
dynamic_favicon: { type: :boolean },
|
dynamic_favicon: { type: :boolean },
|
||||||
enable_quoting: { type: :boolean },
|
enable_quoting: { type: :boolean },
|
||||||
enable_defer: { type: :boolean },
|
enable_defer: { type: :boolean },
|
||||||
|
@ -344,12 +344,12 @@ RSpec.configure do |config|
|
||||||
theme_key_seq: { type: :integer },
|
theme_key_seq: { type: :integer },
|
||||||
allow_private_messages: { type: :boolean },
|
allow_private_messages: { type: :boolean },
|
||||||
enable_allowed_pm_users: { type: :boolean },
|
enable_allowed_pm_users: { type: :boolean },
|
||||||
homepage_id: { type: :string, nullable: true },
|
homepage_id: { type: [:string, :null] },
|
||||||
hide_profile_and_presence: { type: :boolean },
|
hide_profile_and_presence: { type: :boolean },
|
||||||
text_size: { type: :string },
|
text_size: { type: :string },
|
||||||
text_size_seq: { type: :integer },
|
text_size_seq: { type: :integer },
|
||||||
title_count_mode: { type: :string },
|
title_count_mode: { type: :string },
|
||||||
timezone: { type: :string, nullable: true },
|
timezone: { type: [:string, :null] },
|
||||||
skip_new_user_tips: { type: :boolean },
|
skip_new_user_tips: { type: :boolean },
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in New Issue