Package com.atlan.api
Class FilesEndpoint
java.lang.Object
com.atlan.api.AbstractEndpoint
com.atlan.api.HeraclesEndpoint
com.atlan.api.FilesEndpoint
API endpoints for managing files that can be uploaded to Atlan.
-
Nested Class Summary
Nested classes/interfaces inherited from class com.atlan.api.AbstractEndpoint
AbstractEndpoint.RawResponse
-
Field Summary
Fields inherited from class com.atlan.api.AbstractEndpoint
client
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionUpload a file from a local file.upload
(File file, RequestOptions options) Upload a file from a local file.upload
(InputStream fileSrc, String filename) Upload a file from a given input stream.upload
(InputStream fileSrc, String filename, RequestOptions options) Upload a file from a given input stream.Upload a file from a given URL.upload
(String fromUrl, RequestOptions options) Upload a file from a given URL.Methods inherited from class com.atlan.api.HeraclesEndpoint
getBaseUrl
Methods inherited from class com.atlan.api.AbstractEndpoint
getBaseUrl
-
Constructor Details
-
FilesEndpoint
-
-
Method Details
-
upload
Upload a file from a given URL.- Parameters:
fromUrl
- URL from which to retrieve the file (must be network-accessible from client running the code)- Returns:
- details of the uploaded file
- Throws:
AtlanException
- on any API communication issuesMalformedURLException
- if the provided URL is invalidIOException
- on any issues accessing or reading from the provided URL
-
upload
public AtlanFile upload(String fromUrl, RequestOptions options) throws AtlanException, MalformedURLException, IOException Upload a file from a given URL.- Parameters:
fromUrl
- URL from which to retrieve the file (must be network-accessible from client running the code)options
- to override default client settings- Returns:
- details of the uploaded file
- Throws:
AtlanException
- on any API communication issuesMalformedURLException
- if the provided URL is invalidIOException
- on any issues accessing or reading from the provided URL
-
upload
Upload a file from a local file.- Parameters:
file
- local file containing the file- Returns:
- details of the uploaded file
- Throws:
AtlanException
- on any API communication issuesIOException
- on any issues accessing or reading from the provided file
-
upload
Upload a file from a local file.- Parameters:
file
- local file containing the fileoptions
- to override default client settings- Returns:
- details of the uploaded file
- Throws:
AtlanException
- on any API communication issuesIOException
- on any issues accessing or reading from the provided file
-
upload
Upload a file from a given input stream.- Parameters:
fileSrc
- source of the file, as an input streamfilename
- name of the file the InputStream is reading (must include an extension that accurately represents the type of the file)- Returns:
- details of the uploaded file
- Throws:
AtlanException
- on any API communication issues
-
upload
public AtlanFile upload(InputStream fileSrc, String filename, RequestOptions options) throws AtlanException Upload a file from a given input stream.- Parameters:
fileSrc
- source of the file, as an input streamfilename
- name of the file the InputStream is reading (must include an extension that accurately represents the type of the file)options
- to override default client settings- Returns:
- details of the uploaded file
- Throws:
AtlanException
- on any API communication issues
-