Skip to content

docs: Improve descriptions of types (box/box-openapi#527) #461

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 12 commits into from
May 30, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .codegen.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{ "engineHash": "20cb559", "specHash": "2da99e0", "version": "0.6.1" }
{ "engineHash": "20cb559", "specHash": "a54170e", "version": "0.6.1" }
6 changes: 6 additions & 0 deletions Sources/Managers/Files/UpdateFileByIdRequestBody.swift
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ public class UpdateFileByIdRequestBody: Codable, RawJSONReadable {

/// An optional different name for the file. This can be used to
/// rename the file.
///
/// File names must be unique within their parent folder. The name check is case-insensitive, so a file
/// named `New File` cannot be created in a parent folder that already contains a folder named `new file`.
public let name: String?

/// The description for a file. This can be seen in the right-hand sidebar panel
Expand Down Expand Up @@ -78,6 +81,9 @@ public class UpdateFileByIdRequestBody: Codable, RawJSONReadable {
/// - Parameters:
/// - name: An optional different name for the file. This can be used to
/// rename the file.
///
/// File names must be unique within their parent folder. The name check is case-insensitive, so a file
/// named `New File` cannot be created in a parent folder that already contains a folder named `new file`.
/// - description: The description for a file. This can be seen in the right-hand sidebar panel
/// when viewing a file in the Box web app. Additionally, this index is used in
/// the search index of the file, allowing users to find the file by the content
Expand Down
22 changes: 12 additions & 10 deletions Sources/Managers/Folders/CreateFolderRequestBody.swift
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,14 @@ public class CreateFolderRequestBody: Codable, RawJSONReadable {

/// The name for the new folder.
///
/// There are some restrictions to the file name. Names containing
/// The following restrictions to folder names apply: names containing
/// non-printable ASCII characters, forward and backward slashes
/// (`/`, `\`), as well as names with trailing spaces are
/// prohibited.
/// (`/`, `\`), names with trailing spaces, and names `.` and `..` are
/// not allowed.
///
/// Additionally, the names `.` and `..` are
/// not allowed either.
/// Folder names must be unique within their parent folder. The name check is case-insensitive,
/// so a folder named `New Folder` cannot be created in a parent folder that already contains
/// a folder named `new folder`.
public let name: String

/// The parent folder to create the new folder within.
Expand All @@ -43,13 +44,14 @@ public class CreateFolderRequestBody: Codable, RawJSONReadable {
/// - Parameters:
/// - name: The name for the new folder.
///
/// There are some restrictions to the file name. Names containing
/// The following restrictions to folder names apply: names containing
/// non-printable ASCII characters, forward and backward slashes
/// (`/`, `\`), as well as names with trailing spaces are
/// prohibited.
/// (`/`, `\`), names with trailing spaces, and names `.` and `..` are
/// not allowed.
///
/// Additionally, the names `.` and `..` are
/// not allowed either.
/// Folder names must be unique within their parent folder. The name check is case-insensitive,
/// so a folder named `New Folder` cannot be created in a parent folder that already contains
/// a folder named `new folder`.
/// - parent: The parent folder to create the new folder within.
/// - folderUploadEmail:
/// - syncState: Specifies whether a folder should be synced to a
Expand Down
18 changes: 18 additions & 0 deletions Sources/Managers/Folders/UpdateFolderByIdRequestBody.swift
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,15 @@ public class UpdateFolderByIdRequestBody: Codable, RawJSONReadable {


/// The optional new name for this folder.
///
/// The following restrictions to folder names apply: names containing
/// non-printable ASCII characters, forward and backward slashes
/// (`/`, `\`), names with trailing spaces, and names `.` and `..` are
/// not allowed.
///
/// Folder names must be unique within their parent folder. The name check is case-insensitive,
/// so a folder named `New Folder` cannot be created in a parent folder that already contains
/// a folder named `new folder`.
public let name: String?

/// The optional description of this folder
Expand Down Expand Up @@ -89,6 +98,15 @@ public class UpdateFolderByIdRequestBody: Codable, RawJSONReadable {
///
/// - Parameters:
/// - name: The optional new name for this folder.
///
/// The following restrictions to folder names apply: names containing
/// non-printable ASCII characters, forward and backward slashes
/// (`/`, `\`), names with trailing spaces, and names `.` and `..` are
/// not allowed.
///
/// Folder names must be unique within their parent folder. The name check is case-insensitive,
/// so a folder named `New Folder` cannot be created in a parent folder that already contains
/// a folder named `new folder`.
/// - description: The optional description of this folder
/// - syncState: Specifies whether a folder should be synced to a
/// user's device or not. This is used by Box Sync
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,10 @@ public class UploadFileRequestBodyAttributesField: Codable, RawJSONReadable {
}


/// The name of the file
/// The name of the file.
///
/// File names must be unique within their parent folder. The name check is case-insensitive, so a file
/// named `New File` cannot be created in a parent folder that already contains a folder named `new file`.
public let name: String

/// The parent folder to upload the file to
Expand All @@ -36,7 +39,10 @@ public class UploadFileRequestBodyAttributesField: Codable, RawJSONReadable {
/// Initializer for a UploadFileRequestBodyAttributesField.
///
/// - Parameters:
/// - name: The name of the file
/// - name: The name of the file.
///
/// File names must be unique within their parent folder. The name check is case-insensitive, so a file
/// named `New File` cannot be created in a parent folder that already contains a folder named `new file`.
/// - parent: The parent folder to upload the file to
/// - contentCreatedAt: Defines the time the file was originally created at.
///
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,10 @@ public class UploadWithPreflightCheckRequestBodyAttributesField: Codable, RawJSO
}


/// The name of the file
/// The name of the file.
///
/// File names must be unique within their parent folder. The name check is case-insensitive, so a file
/// named `New File` cannot be created in a parent folder that already contains a folder named `new file`.
public let name: String

/// The parent folder to upload the file to
Expand All @@ -40,7 +43,10 @@ public class UploadWithPreflightCheckRequestBodyAttributesField: Codable, RawJSO
/// Initializer for a UploadWithPreflightCheckRequestBodyAttributesField.
///
/// - Parameters:
/// - name: The name of the file
/// - name: The name of the file.
///
/// File names must be unique within their parent folder. The name check is case-insensitive, so a file
/// named `New File` cannot be created in a parent folder that already contains a folder named `new file`.
/// - parent: The parent folder to upload the file to
/// - size: The size of the file in bytes
/// - contentCreatedAt: Defines the time the file was originally created at.
Expand Down