Skip to content

Latest commit

 

History

History
373 lines (251 loc) · 10.7 KB

File metadata and controls

373 lines (251 loc) · 10.7 KB

SeaTable\Client\RowCommentsApi

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

Method HTTP request Description
createRowComment() POST /api-gateway/api/v2/dtables/{base_uuid}/comments/ Create Row Comment
deleteComment() DELETE /api-gateway/api/v2/dtables/{base_uuid}/comments/{comment_id}/ Delete Comment
getComment() GET /api-gateway/api/v2/dtables/{base_uuid}/comments/{comment_id}/ Get Comment
getNumberOfComments() GET /api/v2.1/dtables/{base_uuid}/rows-comments-num/ Get Number of Comments
getRowCommentsCount() GET /api-gateway/api/v2/dtables/{base_uuid}/comments-count/ Get Row Comments Count
listCommentsWithinDays() GET /api-gateway/api/v2/dtables/{base_uuid}/comments-within-days/ List Comments within Days
listRowComments() GET /api-gateway/api/v2/dtables/{base_uuid}/comments/ List Row Comments

createRowComment()

createRowComment($base_uuid, $table_id, $row_id, $create_row_comment): object

Create Row Comment

Create a comment for a certain row.

Example

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

// Configure Bearer authorization: BaseTokenAuth (use the right token for your request)
$config = SeaTable\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_TOKEN');
$apiInstance = new SeaTable\Client\Base\RowCommentsApi(
    new GuzzleHttp\Client(),
    $config
);
$base_uuid = 5c264e76-0e5a-448a-9f34-580b551364ca; // string | The unique identifier of a base. Sometimes also called dtable_uuid.
$table_id = 0000; // string | The id of the table. The id of a table is unique inside a base and is often used to identify a table.
$row_id = YMIviMeERQCUiQhPPqo6Gw; // string | Unique id of a row.
$create_row_comment = new \SeaTable\Client\Base\CreateRowComment(); // \SeaTable\Client\Base\CreateRowComment

try {
    $result = $apiInstance->createRowComment($base_uuid, $table_id, $row_id, $create_row_comment);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling RowCommentsApi->createRowComment: ', $e->getMessage(), PHP_EOL;
}

Parameters

Name Type Description Notes
base_uuid string The unique identifier of a base. Sometimes also called dtable_uuid.
table_id string The id of the table. The id of a table is unique inside a base and is often used to identify a table.
row_id string Unique id of a row.
create_row_comment \SeaTable\Client\Base\CreateRowComment [optional]

Return type

object

Authorization

BaseTokenAuth

deleteComment()

deleteComment($base_uuid, $comment_id): object

Delete Comment

Delete a certain comment by its ID.

Example

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

// Configure Bearer authorization: BaseTokenAuth (use the right token for your request)
$config = SeaTable\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_TOKEN');
$apiInstance = new SeaTable\Client\Base\RowCommentsApi(
    new GuzzleHttp\Client(),
    $config
);
$base_uuid = 5c264e76-0e5a-448a-9f34-580b551364ca; // string | The unique identifier of a base. Sometimes also called dtable_uuid.
$comment_id = 1; // int | The id of the comment.

try {
    $result = $apiInstance->deleteComment($base_uuid, $comment_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling RowCommentsApi->deleteComment: ', $e->getMessage(), PHP_EOL;
}

Parameters

Name Type Description Notes
base_uuid string The unique identifier of a base. Sometimes also called dtable_uuid.
comment_id int The id of the comment.

Return type

object

Authorization

BaseTokenAuth

getComment()

getComment($base_uuid, $comment_id): \SeaTable\Client\Base\GetComment200Response

Get Comment

Get the details of a certain comment with its ID.

Example

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

// Configure Bearer authorization: BaseTokenAuth (use the right token for your request)
$config = SeaTable\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_TOKEN');
$apiInstance = new SeaTable\Client\Base\RowCommentsApi(
    new GuzzleHttp\Client(),
    $config
);
$base_uuid = 5c264e76-0e5a-448a-9f34-580b551364ca; // string | The unique identifier of a base. Sometimes also called dtable_uuid.
$comment_id = 1; // int | The id of the comment.

try {
    $result = $apiInstance->getComment($base_uuid, $comment_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling RowCommentsApi->getComment: ', $e->getMessage(), PHP_EOL;
}

Parameters

Name Type Description Notes
base_uuid string The unique identifier of a base. Sometimes also called dtable_uuid.
comment_id int The id of the comment.

Return type

\SeaTable\Client\Base\GetComment200Response

Authorization

BaseTokenAuth

getNumberOfComments()

getNumberOfComments($base_uuid): object

Get Number of Comments

Get the number of comments for all rows.

Example

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

// Configure Bearer authorization: BaseTokenAuth (use the right token for your request)
$config = SeaTable\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_TOKEN');
$apiInstance = new SeaTable\Client\Base\RowCommentsApi(
    new GuzzleHttp\Client(),
    $config
);
$base_uuid = 5c264e76-0e5a-448a-9f34-580b551364ca; // string | The unique identifier of a base. Sometimes also called dtable_uuid.

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

Parameters

Name Type Description Notes
base_uuid string The unique identifier of a base. Sometimes also called dtable_uuid.

Return type

object

Authorization

BaseTokenAuth

getRowCommentsCount()

getRowCommentsCount($base_uuid, $row_id): object

Get Row Comments Count

Get the number of comments in a certain row. This could be a useful request to check if there's new comments there.

Example

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

// Configure Bearer authorization: BaseTokenAuth (use the right token for your request)
$config = SeaTable\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_TOKEN');
$apiInstance = new SeaTable\Client\Base\RowCommentsApi(
    new GuzzleHttp\Client(),
    $config
);
$base_uuid = 5c264e76-0e5a-448a-9f34-580b551364ca; // string | The unique identifier of a base. Sometimes also called dtable_uuid.
$row_id = YMIviMeERQCUiQhPPqo6Gw; // string | Unique id of a row.

try {
    $result = $apiInstance->getRowCommentsCount($base_uuid, $row_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling RowCommentsApi->getRowCommentsCount: ', $e->getMessage(), PHP_EOL;
}

Parameters

Name Type Description Notes
base_uuid string The unique identifier of a base. Sometimes also called dtable_uuid.
row_id string Unique id of a row.

Return type

object

Authorization

BaseTokenAuth

listCommentsWithinDays()

listCommentsWithinDays($base_uuid, $days): object

List Comments within Days

List all the comments in a base within a given number of days before today.

Example

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

// Configure Bearer authorization: BaseTokenAuth (use the right token for your request)
$config = SeaTable\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_TOKEN');
$apiInstance = new SeaTable\Client\Base\RowCommentsApi(
    new GuzzleHttp\Client(),
    $config
);
$base_uuid = 5c264e76-0e5a-448a-9f34-580b551364ca; // string | The unique identifier of a base. Sometimes also called dtable_uuid.
$days = 7; // int | Number of days to look back for comments.

try {
    $result = $apiInstance->listCommentsWithinDays($base_uuid, $days);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling RowCommentsApi->listCommentsWithinDays: ', $e->getMessage(), PHP_EOL;
}

Parameters

Name Type Description Notes
base_uuid string The unique identifier of a base. Sometimes also called dtable_uuid.
days int Number of days to look back for comments. [optional]

Return type

object

Authorization

BaseTokenAuth

listRowComments()

listRowComments($base_uuid, $row_id): object[]

List Row Comments

List all the comments in a certain row. The returned id value is the ID of each comment.

Example

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

// Configure Bearer authorization: BaseTokenAuth (use the right token for your request)
$config = SeaTable\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_TOKEN');
$apiInstance = new SeaTable\Client\Base\RowCommentsApi(
    new GuzzleHttp\Client(),
    $config
);
$base_uuid = 5c264e76-0e5a-448a-9f34-580b551364ca; // string | The unique identifier of a base. Sometimes also called dtable_uuid.
$row_id = YMIviMeERQCUiQhPPqo6Gw; // string | Unique id of a row.

try {
    $result = $apiInstance->listRowComments($base_uuid, $row_id);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling RowCommentsApi->listRowComments: ', $e->getMessage(), PHP_EOL;
}

Parameters

Name Type Description Notes
base_uuid string The unique identifier of a base. Sometimes also called dtable_uuid.
row_id string Unique id of a row.

Return type

object[]

Authorization

BaseTokenAuth