Package dev.dosya.sdk
Class DosyaClient
java.lang.Object
dev.dosya.sdk.DosyaClient
The main entry point for the Dosya Java SDK.
Provides access to all Dosya API resources through dedicated sub-resource accessors.
Create an instance with either a DosyaClientOptions object for full configuration
or a simple API key string for quick setup.
DosyaClient client = new DosyaClient("dos_your_api_key");
UserProfile profile = client.me().profile();
- Since:
- 0.1.0
-
Constructor Summary
ConstructorsConstructorDescriptionDosyaClient(@NotNull DosyaClientOptions options) Creates a newDosyaClientwith the given options.DosyaClient(@NotNull String apiKey) Creates a newDosyaClientwith a simple API key using default settings. -
Method Summary
Modifier and TypeMethodDescription@NotNull ActivityResourceactivity()Returns the activity resource for activity log operations.@NotNull CommentsResourcecomments()Returns the comments resource for comment operations.@NotNull DownloadResourcedownload()Returns the download resource for file download operations.@NotNull FileRequestsResourceReturns the file requests resource for file request operations.@NotNull FilesResourcefiles()Returns the files resource for file operations.@NotNull FoldersResourcefolders()Returns the folders resource for folder operations.@NotNull MeResourceme()Returns the me resource for authenticated user operations.@NotNull SearchResourcesearch()Returns the search resource for search operations.@NotNull SharesResourceshares()Returns the shares resource for share link operations.@NotNull UploadResourceupload()Returns the upload resource for file upload operations.@NotNull WorkspacesResourceReturns the workspaces resource for workspace operations.
-
Constructor Details
-
DosyaClient
Creates a newDosyaClientwith the given options.- Parameters:
options- the client configuration options- Throws:
NullPointerException- ifoptionsisnullIllegalArgumentException- if the API key does not start with"dos_"
-
DosyaClient
Creates a newDosyaClientwith a simple API key using default settings.- Parameters:
apiKey- the Dosya API key (must start with"dos_")- Throws:
IllegalArgumentException- if the API key does not start with"dos_"
-
-
Method Details
-
files
Returns the files resource for file operations. -
folders
Returns the folders resource for folder operations. -
upload
Returns the upload resource for file upload operations. -
download
Returns the download resource for file download operations. -
workspaces
Returns the workspaces resource for workspace operations. -
fileRequests
Returns the file requests resource for file request operations. -
search
Returns the search resource for search operations. -
comments
Returns the comments resource for comment operations. -
me
Returns the me resource for authenticated user operations. -
activity
Returns the activity resource for activity log operations.
-