Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/Generated/ChatTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ public function queryChannels(GeneratedModels\QueryChannelsRequest $requestData)
return StreamResponse::fromJson($this->makeRequest('POST', $path, $queryParams, $requestData), GeneratedModels\QueryChannelsResponse::class);
}
/**
* Update channels in batch
* Update channels in batch. By default returns task_id for an asynchronous task. With synchronous: true, updateData accepts at most 100 explicit CIDs and returns a positive success_channels_count of channels selected for update after the database write completes, without task_id. Always poll a returned task_id, including when an older node ignores synchronous.
* Sends events:
* - channel.frozen
* - channel.hidden
Expand Down Expand Up @@ -1336,7 +1336,7 @@ public function deleteReminder(string $messageID, ?string $userID = null): Strea
return StreamResponse::fromJson($this->makeRequest('DELETE', $path, $queryParams, $requestData), GeneratedModels\DeleteReminderResponse::class);
}
/**
* Updates an existing reminder
* Updates an existing reminder. remind_at and expires_at are both replaced on every call: omitting either one clears it
* Sends events:
* - reminder.updated
*
Expand All @@ -1354,7 +1354,7 @@ public function updateReminder(string $messageID, GeneratedModels\UpdateReminder
return StreamResponse::fromJson($this->makeRequest('PATCH', $path, $queryParams, $requestData), GeneratedModels\UpdateReminderResponse::class);
}
/**
* Creates a new reminder
* Creates a new reminder. An optional expires_at hides the reminder from every read once it passes and stops it counting against the per-user reminder cap
* Sends events:
* - reminder.created
*
Expand Down
20 changes: 19 additions & 1 deletion src/Generated/CommonTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,20 @@ public function updateBlockList(string $name, GeneratedModels\UpdateBlockListReq
// Use the provided request data array directly
return StreamResponse::fromJson($this->makeRequest('PUT', $path, $queryParams, $requestData), GeneratedModels\UpdateBlockListResponse::class);
}
/**
* Validates that Stream can publish to a customer-owned GCP Pub/Sub topic
*
* @param GeneratedModels\CheckGCPPubSubRequest $requestData
* @return StreamResponse<GeneratedModels\CheckGCPPubSubResponse>
* @throws StreamException
*/
public function checkGCPPubSub(GeneratedModels\CheckGCPPubSubRequest $requestData): StreamResponse {
$path = '/api/v2/check_gcp_pubsub';

$queryParams = [];
// Use the provided request data array directly
return StreamResponse::fromJson($this->makeRequest('POST', $path, $queryParams, $requestData), GeneratedModels\CheckGCPPubSubResponse::class);
}
/**
* Sends a test message via push, this is a test endpoint to verify your push settings
*
Expand Down Expand Up @@ -805,15 +819,19 @@ public function deletePollOption(string $pollID, string $optionID, ?string $user
*
* @param string $pollID
* @param string $optionID
* @param ?string $userID
* @return StreamResponse<GeneratedModels\PollOptionResponse>
* @throws StreamException
*/
public function getPollOption(string $pollID, string $optionID): StreamResponse {
public function getPollOption(string $pollID, string $optionID, ?string $userID = null): StreamResponse {
$path = '/api/v2/polls/{poll_id}/options/{option_id}';
$path = str_replace('{poll_id}', (string) $pollID, $path);
$path = str_replace('{option_id}', (string) $optionID, $path);

$queryParams = [];
if ($userID !== null) {
$queryParams['user_id'] = $userID;
}
$requestData = null;
return StreamResponse::fromJson($this->makeRequest('GET', $path, $queryParams, $requestData), GeneratedModels\PollOptionResponse::class);
}
Expand Down
142 changes: 136 additions & 6 deletions src/Generated/FeedsTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -357,13 +357,17 @@ public function deleteActivity(string $id, ?bool $hardDelete = null, ?bool $dele
* @param string $id
* @param ?string $commentSort
* @param ?int $commentLimit
* @param ?bool $skipOwnFollowings
* @param ?string $userID
* @param ?string $language
* @param ?bool $translateText
* @param ?bool $includeTopLevelCommentCount
* @param ?bool $includeSoftDeletedActivities
* @param ?bool $includeModeratedActivities
* @return StreamResponse<GeneratedModels\GetActivityResponse>
* @throws StreamException
*/
public function getActivity(string $id, ?string $commentSort = null, ?int $commentLimit = null, ?string $userID = null, ?string $language = null, ?bool $translateText = null): StreamResponse {
public function getActivity(string $id, ?string $commentSort = null, ?int $commentLimit = null, ?bool $skipOwnFollowings = null, ?string $userID = null, ?string $language = null, ?bool $translateText = null, ?bool $includeTopLevelCommentCount = null, ?bool $includeSoftDeletedActivities = null, ?bool $includeModeratedActivities = null): StreamResponse {
$path = '/api/v2/feeds/activities/{id}';
$path = str_replace('{id}', (string) $id, $path);

Expand All @@ -374,6 +378,9 @@ public function getActivity(string $id, ?string $commentSort = null, ?int $comme
if ($commentLimit !== null) {
$queryParams['comment_limit'] = $commentLimit;
}
if ($skipOwnFollowings !== null) {
$queryParams['skip_own_followings'] = $skipOwnFollowings;
}
if ($userID !== null) {
$queryParams['user_id'] = $userID;
}
Expand All @@ -383,11 +390,20 @@ public function getActivity(string $id, ?string $commentSort = null, ?int $comme
if ($translateText !== null) {
$queryParams['translate_text'] = $translateText;
}
if ($includeTopLevelCommentCount !== null) {
$queryParams['include_top_level_comment_count'] = $includeTopLevelCommentCount;
}
if ($includeSoftDeletedActivities !== null) {
$queryParams['include_soft_deleted_activities'] = $includeSoftDeletedActivities;
}
if ($includeModeratedActivities !== null) {
$queryParams['include_moderated_activities'] = $includeModeratedActivities;
}
$requestData = null;
return StreamResponse::fromJson($this->makeRequest('GET', $path, $queryParams, $requestData), GeneratedModels\GetActivityResponse::class);
}
/**
* Updates certain fields of the activity. Use 'set' to update specific fields and 'unset' to remove fields. This allows you to update only the fields you need without replacing the entire activity. Useful for updating reply restrictions ('restrict_replies'), mentioned users, or custom data.
* Updates certain fields of the activity. Use 'set' to update specific fields and 'unset' to remove fields. This allows you to update only the fields you need without replacing the entire activity. Useful for updating reply restrictions ('restrict_replies'), mentioned users, or custom data. Changing `feeds` is a placement change (add/delete on those feeds), not an activity content update.
* Sends events:
* - feeds.activity.updated
*
Expand All @@ -405,7 +421,7 @@ public function updateActivityPartial(string $id, GeneratedModels\UpdateActivity
return StreamResponse::fromJson($this->makeRequest('PATCH', $path, $queryParams, $requestData), GeneratedModels\UpdateActivityPartialResponse::class);
}
/**
* Replaces an activity with the provided data. Use this to update text, attachments, reply restrictions ('restrict_replies'), mentioned users, and other activity fields. Note: This is a full update - any fields not provided will be cleared.
* Replaces an activity with the provided data. Use this to update text, attachments, reply restrictions ('restrict_replies'), mentioned users, and other activity fields. Note: This is a full update - any fields not provided will be cleared. Changing `feeds` is a placement change (add/delete on those feeds), not an activity content update.
* Sends events:
* - feeds.activity.updated
*
Expand Down Expand Up @@ -531,16 +547,20 @@ public function queryBookmarks(GeneratedModels\QueryBookmarksRequest $requestDat
* Delete collections in a batch operation. Users can only delete their own collections.
*
* @param array $collectionRefs
* @param ?bool $hardDelete
* @return StreamResponse<GeneratedModels\DeleteCollectionsResponse>
* @throws StreamException
*/
public function deleteCollections(array $collectionRefs): StreamResponse {
public function deleteCollections(array $collectionRefs, ?bool $hardDelete = null): StreamResponse {
$path = '/api/v2/feeds/collections';

$queryParams = [];
if ($collectionRefs !== null) {
$queryParams['collection_refs'] = $collectionRefs;
}
if ($hardDelete !== null) {
$queryParams['hard_delete'] = $hardDelete;
}
$requestData = null;
return StreamResponse::fromJson($this->makeRequest('DELETE', $path, $queryParams, $requestData), GeneratedModels\DeleteCollectionsResponse::class);
}
Expand Down Expand Up @@ -636,10 +656,11 @@ public function queryCollections(GeneratedModels\QueryCollectionsRequest $reques
* @param ?int $limit
* @param ?string $prev
* @param ?string $next
* @param ?bool $includeTopLevelCommentCount
* @return StreamResponse<GeneratedModels\GetCommentsResponse>
* @throws StreamException
*/
public function getComments(string $objectID, string $objectType, ?int $depth = null, ?string $sort = null, ?int $repliesLimit = null, ?string $idAround = null, ?string $language = null, ?bool $translateText = null, ?string $userID = null, ?int $limit = null, ?string $prev = null, ?string $next = null): StreamResponse {
public function getComments(string $objectID, string $objectType, ?int $depth = null, ?string $sort = null, ?int $repliesLimit = null, ?string $idAround = null, ?string $language = null, ?bool $translateText = null, ?string $userID = null, ?int $limit = null, ?string $prev = null, ?string $next = null, ?bool $includeTopLevelCommentCount = null): StreamResponse {
$path = '/api/v2/feeds/comments';

$queryParams = [];
Expand Down Expand Up @@ -679,6 +700,9 @@ public function getComments(string $objectID, string $objectType, ?int $depth =
if ($next !== null) {
$queryParams['next'] = $next;
}
if ($includeTopLevelCommentCount !== null) {
$queryParams['include_top_level_comment_count'] = $includeTopLevelCommentCount;
}
$requestData = null;
return StreamResponse::fromJson($this->makeRequest('GET', $path, $queryParams, $requestData), GeneratedModels\GetCommentsResponse::class);
}
Expand Down Expand Up @@ -867,6 +891,22 @@ public function updateComment(string $id, GeneratedModels\UpdateCommentRequest $
// Use the provided request data array directly
return StreamResponse::fromJson($this->makeRequest('PATCH', $path, $queryParams, $requestData), GeneratedModels\UpdateCommentResponse::class);
}
/**
* Hide or unhide a comment for the current user
*
* @param string $id
* @param GeneratedModels\CommentFeedbackRequest $requestData
* @return StreamResponse<GeneratedModels\CommentFeedbackResponse>
* @throws StreamException
*/
public function commentFeedback(string $id, GeneratedModels\CommentFeedbackRequest $requestData): StreamResponse {
$path = '/api/v2/feeds/comments/{id}/feedback';
$path = str_replace('{id}', (string) $id, $path);

$queryParams = [];
// Use the provided request data array directly
return StreamResponse::fromJson($this->makeRequest('POST', $path, $queryParams, $requestData), GeneratedModels\CommentFeedbackResponse::class);
}
/**
* Updates certain fields of the comment. Use 'set' to update specific fields and 'unset' to remove fields.
* Sends events:
Expand Down Expand Up @@ -1873,6 +1913,61 @@ public function updateMembershipLevel(string $id, GeneratedModels\UpdateMembersh
// Use the provided request data array directly
return StreamResponse::fromJson($this->makeRequest('PATCH', $path, $queryParams, $requestData), GeneratedModels\UpdateMembershipLevelResponse::class);
}
/**
* Returns the feeds retention policies configured for the app. Server-side only.
*
* @return StreamResponse<GeneratedModels\GetFeedsRetentionPolicyResponse>
* @throws StreamException
*/
public function feedsGetRetentionPolicy(): StreamResponse {
$path = '/api/v2/feeds/retention_policy';

$queryParams = [];
$requestData = null;
return StreamResponse::fromJson($this->makeRequest('GET', $path, $queryParams, $requestData), GeneratedModels\GetFeedsRetentionPolicyResponse::class);
}
/**
* Creates or updates a feeds retention policy for the app (an app may have multiple, each scoped to feed groups). Server-side only.
*
* @param GeneratedModels\SetFeedsRetentionPolicyRequest $requestData
* @return StreamResponse<GeneratedModels\SetFeedsRetentionPolicyResponse>
* @throws StreamException
*/
public function feedsSetRetentionPolicy(GeneratedModels\SetFeedsRetentionPolicyRequest $requestData): StreamResponse {
$path = '/api/v2/feeds/retention_policy';

$queryParams = [];
// Use the provided request data array directly
return StreamResponse::fromJson($this->makeRequest('POST', $path, $queryParams, $requestData), GeneratedModels\SetFeedsRetentionPolicyResponse::class);
}
/**
* Removes the named feeds retention policy for the app (an app may hold several). Server-side only.
*
* @param GeneratedModels\DeleteFeedsRetentionPolicyRequest $requestData
* @return StreamResponse<GeneratedModels\DeleteFeedsRetentionPolicyResponse>
* @throws StreamException
*/
public function feedsDeleteRetentionPolicy(GeneratedModels\DeleteFeedsRetentionPolicyRequest $requestData): StreamResponse {
$path = '/api/v2/feeds/retention_policy/delete';

$queryParams = [];
// Use the provided request data array directly
return StreamResponse::fromJson($this->makeRequest('POST', $path, $queryParams, $requestData), GeneratedModels\DeleteFeedsRetentionPolicyResponse::class);
}
/**
* Returns filtered and sorted feeds retention cleanup run history for the app. Supports filter_conditions on 'policy' and 'date' fields. Server-side only.
*
* @param GeneratedModels\GetFeedsRetentionPolicyRunsRequest $requestData
* @return StreamResponse<GeneratedModels\GetFeedsRetentionPolicyRunsResponse>
* @throws StreamException
*/
public function feedsGetRetentionPolicyRuns(GeneratedModels\GetFeedsRetentionPolicyRunsRequest $requestData): StreamResponse {
$path = '/api/v2/feeds/retention_policy/runs';

$queryParams = [];
// Use the provided request data array directly
return StreamResponse::fromJson($this->makeRequest('POST', $path, $queryParams, $requestData), GeneratedModels\GetFeedsRetentionPolicyRunsResponse::class);
}
/**
* Queries revision history for activities and comments
*
Expand Down Expand Up @@ -1977,7 +2072,26 @@ public function exportFeedUserData(string $userID): StreamResponse {
return StreamResponse::fromJson($this->makeRequest('POST', $path, $queryParams, $requestData), GeneratedModels\ExportFeedUserDataResponse::class);
}
/**
* Returns the user's most common interest tags ranked by the number of distinct activities they reacted to that carried each tag. Client-side callers may only read their own interests; server-side callers may fetch any user. Results are sorted by descending count, then alphabetically by tag.
* Removes the given interest tags from a user, whether they were set manually or computed from reactions. A removed computed tag returns on the next recomputation if the user's reactions still support it; to keep a tag out of ranking for good, set it with a weight of 0 or below instead. Client-side callers may only manage their own interests; server-side callers may manage any user. Returns the user's remaining interests.
*
* @param string $userID
* @param array $tags
* @return StreamResponse<GeneratedModels\DeleteUserInterestsResponse>
* @throws StreamException
*/
public function deleteUserInterests(string $userID, array $tags): StreamResponse {
$path = '/api/v2/feeds/users/{user_id}/interests';
$path = str_replace('{user_id}', (string) $userID, $path);

$queryParams = [];
if ($tags !== null) {
$queryParams['tags'] = $tags;
}
$requestData = null;
return StreamResponse::fromJson($this->makeRequest('DELETE', $path, $queryParams, $requestData), GeneratedModels\DeleteUserInterestsResponse::class);
}
/**
* Returns the user's interest tags with their ranking weights: tags computed from the activities the user reacted to and tags set manually through the API. Client-side callers may only read their own interests; server-side callers may fetch any user. Results are sorted by descending weight, then manually set tags before computed ones, then descending count, then alphabetically by tag.
*
* @param string $userID
* @param ?int $limit
Expand All @@ -1995,4 +2109,20 @@ public function getUserInterests(string $userID, ?int $limit = null): StreamResp
$requestData = null;
return StreamResponse::fromJson($this->makeRequest('GET', $path, $queryParams, $requestData), GeneratedModels\GetUserInterestsResponse::class);
}
/**
* Adds or updates interest tags on a user with explicit ranking weights. Tags set this way rank above the tags computed from the user's reactions at equal weight and are never overwritten by them. Client-side callers may only manage their own interests; server-side callers may manage any user. Returns the user's full interest list after the write.
*
* @param string $userID
* @param GeneratedModels\UpsertUserInterestsRequest $requestData
* @return StreamResponse<GeneratedModels\UpsertUserInterestsResponse>
* @throws StreamException
*/
public function upsertUserInterests(string $userID, GeneratedModels\UpsertUserInterestsRequest $requestData): StreamResponse {
$path = '/api/v2/feeds/users/{user_id}/interests';
$path = str_replace('{user_id}', (string) $userID, $path);

$queryParams = [];
// Use the provided request data array directly
return StreamResponse::fromJson($this->makeRequest('PUT', $path, $queryParams, $requestData), GeneratedModels\UpsertUserInterestsResponse::class);
}
}
14 changes: 14 additions & 0 deletions src/Generated/VideoTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,20 @@ public function queryCallMembers(GeneratedModels\QueryCallMembersRequest $reques
// Use the provided request data array directly
return StreamResponse::fromJson($this->makeRequest('POST', $path, $queryParams, $requestData), GeneratedModels\QueryCallMembersResponse::class);
}
/**
* Returns a call's ring attempts, newest first. A session can be rung more than once, and the session-level accepted_by / rejected_by / missed_by maps flatten every ring together; an attempt says which ring a user acted on, which devices it reached, and who settled it and why. Pass call_session_id to limit the read to one session.
*
* @param GeneratedModels\QueryCallRingAttemptsRequest $requestData
* @return StreamResponse<GeneratedModels\QueryCallRingAttemptsResponse>
* @throws StreamException
*/
public function queryCallRingAttempts(GeneratedModels\QueryCallRingAttemptsRequest $requestData): StreamResponse {
$path = '/api/v2/video/call/ring_attempts';

$queryParams = [];
// Use the provided request data array directly
return StreamResponse::fromJson($this->makeRequest('POST', $path, $queryParams, $requestData), GeneratedModels\QueryCallRingAttemptsResponse::class);
}
/**
*
* @param GeneratedModels\QueryCallStatsRequest $requestData
Expand Down
Loading
Loading