Skip to content

Latest commit

 

History

History
259 lines (171 loc) · 6.45 KB

File metadata and controls

259 lines (171 loc) · 6.45 KB

SeaTable\Client\FilesImagesCustomFolderApi

All URIs are relative to https://cloud.seatable.io, except if the operation defines another base path.

Method HTTP request Description
deleteBaseCustomFolderAsset() DELETE /api/v2.1/dtable/custom/app-asset-file/ Delete a Base Asset in Custom Folder
getCustomDownloadLink() GET /api/v2.1/dtable/custom/app-download-link/ Get Download Link
getCustomFileMetadata() GET /api/v2.1/dtable/custom/app-asset-file/ Get File Metadata
getCustomFiles() GET /api/v2.1/dtable/custom/app-asset-dir/ Get Files from Folder
getCustomUploadLink() GET /api/v2.1/dtable/custom/app-upload-link/ Get Upload Link

deleteBaseCustomFolderAsset()

deleteBaseCustomFolderAsset($path): object

Delete a Base Asset in Custom Folder

Delete a base's attachment in custom folder.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer authorization: ApiTokenAuth (use the right token for your request)
$config = SeaTable\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_TOKEN');
$apiInstance = new SeaTable\Client\File\FilesImagesCustomFolderApi(
    new GuzzleHttp\Client(),
    $config
);
$path = /supplierOne/b374.pdf; // string | Path and name of the file in the custom folder

try {
    $result = $apiInstance->deleteBaseCustomFolderAsset($path);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling FilesImagesCustomFolderApi->deleteBaseCustomFolderAsset: ', $e->getMessage(), PHP_EOL;
}

Parameters

Name Type Description Notes
path string Path and name of the file in the custom folder

Return type

object

Authorization

ApiTokenAuth

getCustomDownloadLink()

getCustomDownloadLink($path): object

Get Download Link

Get a temporary download link for a file in a custom folder.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer authorization: ApiTokenAuth (use the right token for your request)
$config = SeaTable\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_TOKEN');
$apiInstance = new SeaTable\Client\File\FilesImagesCustomFolderApi(
    new GuzzleHttp\Client(),
    $config
);
$path = /supplierOne/b374.pdf; // string | Path and name of the file in the custom folder

try {
    $result = $apiInstance->getCustomDownloadLink($path);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling FilesImagesCustomFolderApi->getCustomDownloadLink: ', $e->getMessage(), PHP_EOL;
}

Parameters

Name Type Description Notes
path string Path and name of the file in the custom folder

Return type

object

Authorization

ApiTokenAuth

getCustomFileMetadata()

getCustomFileMetadata($path, $name): object

Get File Metadata

Get metadata (name, size, last update) of a file in a custom folder.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer authorization: ApiTokenAuth (use the right token for your request)
$config = SeaTable\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_TOKEN');
$apiInstance = new SeaTable\Client\File\FilesImagesCustomFolderApi(
    new GuzzleHttp\Client(),
    $config
);
$path = /; // string | Path of the custom folder
$name = b374.pdf; // string | Name of the file in the custom folder

try {
    $result = $apiInstance->getCustomFileMetadata($path, $name);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling FilesImagesCustomFolderApi->getCustomFileMetadata: ', $e->getMessage(), PHP_EOL;
}

Parameters

Name Type Description Notes
path string Path of the custom folder
name string Name of the file in the custom folder

Return type

object

Authorization

ApiTokenAuth

getCustomFiles()

getCustomFiles($path): object

Get Files from Folder

List files and subdirectories in a custom folder of a base.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer authorization: ApiTokenAuth (use the right token for your request)
$config = SeaTable\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_TOKEN');
$apiInstance = new SeaTable\Client\File\FilesImagesCustomFolderApi(
    new GuzzleHttp\Client(),
    $config
);
$path = /; // string | Path of the custom folder

try {
    $result = $apiInstance->getCustomFiles($path);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling FilesImagesCustomFolderApi->getCustomFiles: ', $e->getMessage(), PHP_EOL;
}

Parameters

Name Type Description Notes
path string Path of the custom folder

Return type

object

Authorization

ApiTokenAuth

getCustomUploadLink()

getCustomUploadLink($path): object

Get Upload Link

Get a temporary upload link for uploading files to a custom folder.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure Bearer authorization: ApiTokenAuth (use the right token for your request)
$config = SeaTable\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_TOKEN');
$apiInstance = new SeaTable\Client\File\FilesImagesCustomFolderApi(
    new GuzzleHttp\Client(),
    $config
);
$path = /; // string | Path of the custom folder

try {
    $result = $apiInstance->getCustomUploadLink($path);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling FilesImagesCustomFolderApi->getCustomUploadLink: ', $e->getMessage(), PHP_EOL;
}

Parameters

Name Type Description Notes
path string Path of the custom folder

Return type

object

Authorization

ApiTokenAuth