Skip to content

feat(generated): Agents (batch 13ebc8c1) - #611

Merged
workos-sdk-automation[bot] merged 2 commits into
mainfrom
oagen/batch-13ebc8c1
Sep 1, 2026
Merged

feat(generated): Agents (batch 13ebc8c1)#611
workos-sdk-automation[bot] merged 2 commits into
mainfrom
oagen/batch-13ebc8c1

Conversation

@workos-sdk-automation

Copy link
Copy Markdown
Contributor

Summary

Regenerated SDK from spec changes.

Triggered by workos/openapi-spec@b6350ef

@workos-sdk-automation workos-sdk-automation Bot added the autogenerated Autogenerated code or content label Sep 1, 2026
@workos-sdk-automation
workos-sdk-automation Bot requested review from a team as code owners September 1, 2026 21:42
@workos-sdk-automation workos-sdk-automation Bot added the autogenerated Autogenerated code or content label Sep 1, 2026
@greptile-apps

greptile-apps Bot commented Sep 1, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

The PR regenerates the Agents SDK surface to make blueprint session settings optional and add agent-token validation.

  • Adds ValidateBlueprintToken and its request and response models.
  • Adds generated fixtures, manifest entries, synchronization metadata, and changelog information.
  • Adds endpoint coverage, although the request serialization assertion is incomplete.

Confidence Score: 4/5

The PR appears safe to merge, with a non-blocking test gap around serialization of the required agent access token.

The generated method and response model follow existing SDK conventions, but the new test uses an empty request and would not catch malformed or missing token serialization.

Files Needing Attention: agents_test.go

Important Files Changed

Filename Overview
agents.go Adds the typed token-validation request and endpoint method and makes blueprint session settings optional.
models.go Adds the token-validation response model using timestamp and nullable-string conventions consistent with related generated models.
agents_test.go Covers routing and response decoding for the new endpoint but does not verify its required token request field.
.oagen-manifest.json Registers the generated request and response fixtures and maps the new endpoint to its SDK method.

Sequence Diagram

sequenceDiagram
  participant App as Go application
  participant SDK as AgentService
  participant API as WorkOS Agents API
  App->>SDK: ValidateBlueprintToken(blueprintID, token)
  SDK->>API: "POST /agents/blueprints/{id}/tokens/validate"
  alt Token is valid
    API-->>SDK: AgentTokenValidation
    SDK-->>App: Claims and session metadata
  else Token is invalid
    API-->>SDK: Stable API error
    SDK-->>App: error
  end
Loading
Prompt To Fix All With AI
### Issue 1
agents_test.go:187
**Required token remains untested**

The test sends an empty `AgentsValidateBlueprintTokenParams` and never asserts the decoded request body, so it continues passing when `agent_access_token` is empty or serialized under the wrong name, leaving real API rejections uncovered.

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Reviews (1): Last reviewed commit: "chore(generated): add release notes frag..." | Re-trigger Greptile

Comment thread agents_test.go
defer server.Close()

client := workos.NewClient("sk_test", workos.WithBaseURL(server.URL))
result, err := client.Agents().ValidateBlueprintToken(context.Background(), "test_agent_blueprint_id", &workos.AgentsValidateBlueprintTokenParams{})

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Required token remains untested

The test sends an empty AgentsValidateBlueprintTokenParams and never asserts the decoded request body, so it continues passing when agent_access_token is empty or serialized under the wrong name, leaving real API rejections uncovered.

Prompt To Fix With AI
This is a comment left during a code review.
Path: agents_test.go
Line: 187

Comment:
**Required token remains untested**

The test sends an empty `AgentsValidateBlueprintTokenParams` and never asserts the decoded request body, so it continues passing when `agent_access_token` is empty or serialized under the wrong name, leaving real API rejections uncovered.

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

@workos-sdk-automation
workos-sdk-automation Bot merged commit d339bf4 into main Sep 1, 2026
7 checks passed
@workos-sdk-automation
workos-sdk-automation Bot deleted the oagen/batch-13ebc8c1 branch September 1, 2026 21:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

autogenerated Autogenerated code or content

Development

Successfully merging this pull request may close these issues.

0 participants