Skip to content

Commit

Permalink
chore: sync changes from updated openapi doc
Browse files Browse the repository at this point in the history
  • Loading branch information
ewanharris committed Jun 11, 2024
1 parent 0a1dc22 commit af95529
Show file tree
Hide file tree
Showing 25 changed files with 66 additions and 44 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -463,7 +463,7 @@ const { responses } = await fgaClient.batchCheck([{
user: "user:81684243-9356-4421-8fbf-a4f8d36aa31b",
relation: "viewer",
object: "document:roadmap",
contextual_tuples: [{
contextualTuples: [{
user: "user:81684243-9356-4421-8fbf-a4f8d36aa31b",
relation: "writer",
object: "document:roadmap"
Expand Down Expand Up @@ -492,7 +492,7 @@ responses = [{
user: "user:81684243-9356-4421-8fbf-a4f8d36aa31b",
relation: "viewer",
object: "document:roadmap",
contextual_tuples: [{
contextualTuples: [{
user: "user:81684243-9356-4421-8fbf-a4f8d36aa31b",
relation: "writer",
object: "document:roadmap"
Expand Down Expand Up @@ -538,7 +538,7 @@ const response = await fgaClient.listObjects({
user: "user:81684243-9356-4421-8fbf-a4f8d36aa31b",
relation: "viewer",
type: "document",
contextual_tuples: [{
contextualTuples: [{
user: "user:81684243-9356-4421-8fbf-a4f8d36aa31b",
relation: "writer",
object: "document:budget"
Expand All @@ -564,7 +564,7 @@ const response = await fgaClient.listRelations({
user: "user:81684243-9356-4421-8fbf-a4f8d36aa31b",
object: "document:roadmap",
relations: ["can_view", "can_edit", "can_delete"],
contextual_tuples: [{
contextualTuples: [{
user: "user:81684243-9356-4421-8fbf-a4f8d36aa31b",
relation: "writer",
object: "document:roadmap"
Expand Down
27 changes: 14 additions & 13 deletions api.ts

Large diffs are not rendered by default.

31 changes: 26 additions & 5 deletions apiModel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down Expand Up @@ -693,7 +693,7 @@ export interface ListUsersRequest {
*/
relation: string;
/**
*
* The type of results returned. Only accepts exactly one value.
* @type {Array<UserTypeFilter>}
* @memberof ListUsersRequest
*/
Expand Down Expand Up @@ -1355,7 +1355,7 @@ export enum TypeName {
}

/**
*
* Type bound public access. Normally represented using the `<type>:*` syntax `employee:*` represents every object of type `employee`, including those not currently present in the system See https://openfga.dev/docs/concepts#what-is-type-bound-public-access
* @export
* @interface TypedWildcard
*/
Expand All @@ -1367,6 +1367,27 @@ export interface TypedWildcard {
*/
type: string;
}
/**
*
* @export
* @interface UnauthenticatedResponse
*/
export interface UnauthenticatedResponse {
/**
*
* @type {ErrorCode}
* @memberof UnauthenticatedResponse
*/
code?: ErrorCode;
/**
*
* @type {string}
* @memberof UnauthenticatedResponse
*/
message?: string;
}


/**
*
* @export
Expand Down Expand Up @@ -1400,7 +1421,7 @@ export interface UnprocessableContentMessageResponse {


/**
*
* User. Represents any possible value for a user (subject or principal). Can be a: - Specific user object e.g.: \'user:will\', \'folder:marketing\', \'org:contoso\', ...) - Specific userset (e.g. \'group:engineering#member\') - Public-typed wildcard (e.g. \'user:*\') See https://openfga.dev/docs/concepts#what-is-a-user
* @export
* @interface User
*/
Expand Down Expand Up @@ -1551,7 +1572,7 @@ export interface UsersetTreeTupleToUserset {
computed: Array<Computed>;
}
/**
*
* Userset. A set or group of users, represented in the `<type>:<id>#<relation>` format `group:fga#member` represents all members of group FGA, not to be confused by `group:fga` which represents the group itself as a specific object. See: https://openfga.dev/docs/modeling/building-blocks/usersets#what-is-a-userset
* @export
* @interface UsersetUser
*/
Expand Down
2 changes: 1 addition & 1 deletion base.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion client.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion common.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion configuration.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion credentials/credentials.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion credentials/index.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion credentials/types.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion errors.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion tests/client.test.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion tests/helpers/default-config.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion tests/helpers/index.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion tests/helpers/nocks.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion tests/index.test.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion tests/validation.test.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion utils/assert-never.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion utils/chunk-array.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion utils/generate-random-id.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion utils/index.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion utils/set-header-if-not-set.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion utils/set-not-enumerable-property.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down
2 changes: 1 addition & 1 deletion validation.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* JavaScript and Node.js SDK for OpenFGA
*
* API version: 0.1
* API version: 1.x
* Website: https://openfga.dev
* Documentation: https://openfga.dev/docs
* Support: https://openfga.dev/community
Expand Down

0 comments on commit af95529

Please sign in to comment.