Laravel AT Protocol Client (alpha & unstable)
3
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge branch 'refs/heads/dev'

+6 -4
+6 -4
src/Enums/Scope.php
··· 14 14 * Build a repo scope string for record operations. 15 15 * 16 16 * @param string $collection The collection NSID (e.g., 'app.bsky.feed.post') 17 - * @param string|null $action The action (create, update, delete) 17 + * @param array|null $actions The action (create, update, delete) 18 + * 19 + * @return string 18 20 */ 19 - public static function repo(string $collection, ?string $action = null): string 21 + public static function repo(string $collection, ?array $actions = []): string 20 22 { 21 23 $scope = "repo:{$collection}"; 22 24 23 - if ($action !== null) { 24 - $scope .= "?action={$action}"; 25 + if (!empty($actions)) { 26 + $scope .= '?' . implode('&', array_map(fn ($action) => "action={$action}", $actions)); 25 27 } 26 28 27 29 return $scope;