All Products
Search
Document Center

Apsara File Storage NAS:CreateFile

Last Updated:May 23, 2024

Creates a directory or file.

Operation description

  • This operation is only available to some users.
  • This operation supports only General-purpose NAS file systems that use the Server Message Block (SMB) protocol and have Resource Access Management (RAM) enabled.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

Authorization information

There is currently no authorization information disclosed in the API.

Request parameters

ParameterTypeRequiredDescriptionExample
FileSystemIdstringYes

The ID of the file system.

1ca404****
PathstringYes

The absolute path of the directory or file. The path must start and end with a forward slash (/) and must be 2 to 1024 characters in length.

/test/
TypestringYes

The type of the object. Valid values:

  • File
  • Directory
File
OwnerstringNo

The ID of the portable account. The ID must be a 16-digit string. The string can contain digits and lowercase letters.

378cc7630f26****
OwnerAccessInheritablebooleanNo

Specifies whether to share the directory. Valid values:

  • false (default): does not share the directory.
  • true: shares the directory.
Note
  • This parameter takes effect only if the Type parameter is set to Directory and the Owner parameter is not empty.
  • The permissions on a directory can be inherited by the owner. The owner has read and write permissions on the subdirectories and subfiles created in the directory, even if they are created by others.
  • false

    Response parameters

    ParameterTypeDescriptionExample
    object

    Schema of Response

    RequestIdstring

    The request ID.

    2D69A58F-345C-4FDE-88E4-BF518948****

    Examples

    Sample success responses

    JSONformat

    {
      "RequestId": "2D69A58F-345C-4FDE-88E4-BF518948****"
    }

    Error codes

    For a list of error codes, visit the Service error codes.

    Change history

    Change timeSummary of changesOperation
    No change history