Class: DropboxApi::Endpoints::Files::CreateFolder

Inherits:
Rpc
  • Object
show all
Defined in:
lib/dropbox_api/endpoints/files/create_folder.rb

Constant Summary collapse

Method =
:post
Path =
'/2/files/create_folder'
ResultType =
DropboxApi::Metadata::Folder
ErrorType =
DropboxApi::Errors::CreateFolderError

Instance Method Summary collapse

Methods inherited from Rpc

#build_connection, #build_request, #request_body

Methods inherited from Base

add_endpoint, #initialize

Constructor Details

This class inherits a constructor from DropboxApi::Endpoints::Base

Instance Method Details

#create_folder(path) ⇒ DropboxApi::Metadata::Folder

Create a folder at a given path.

Parameters:

  • path (String)

    Path in the user's Dropbox to create.

Returns:



13
14
15
16
17
# File 'lib/dropbox_api/endpoints/files/create_folder.rb', line 13

add_endpoint :create_folder do |path|
  perform_request({
    path: path
  })
end