From aba07e323388383591e2b585cfa900bce7d5841d Mon Sep 17 00:00:00 2001
From: "stainless-app[bot]"
<142633134+stainless-app[bot]@users.noreply.github.com>
Date: Wed, 13 Nov 2024 20:18:20 +0000
Subject: [PATCH] chore(api): update spec version (#607)
---
.stats.yml | 2 +-
api.md | 1 +
src/index.ts | 2 ++
src/resources/index.ts | 1 +
src/resources/messages.ts | 5 ++++-
5 files changed, 9 insertions(+), 2 deletions(-)
diff --git a/.stats.yml b/.stats.yml
index 6c87def4..2d482a8b 100644
--- a/.stats.yml
+++ b/.stats.yml
@@ -1,2 +1,2 @@
configured_endpoints: 10
-openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/anthropic-fe4fbf0720b4ea03b05ff5225d36c94e06ab7aadbc4b227d0d35c4522b60bdb7.yml
+openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/anthropic-cf96271afd65b396dc71c4e897d1d55a9526c122e3890bc87b5ff33316c93853.yml
diff --git a/api.md b/api.md
index 05e453e1..31400a34 100644
--- a/api.md
+++ b/api.md
@@ -4,6 +4,7 @@ Types:
- ContentBlock
- ContentBlockDeltaEvent
+- ContentBlockParam
- ContentBlockStartEvent
- ContentBlockStopEvent
- ImageBlockParam
diff --git a/src/index.ts b/src/index.ts
index 14c430b1..e1425008 100644
--- a/src/index.ts
+++ b/src/index.ts
@@ -17,6 +17,7 @@ import {
import {
ContentBlock,
ContentBlockDeltaEvent,
+ ContentBlockParam,
ContentBlockStartEvent,
ContentBlockStopEvent,
ImageBlockParam,
@@ -309,6 +310,7 @@ export declare namespace Anthropic {
Messages as Messages,
type ContentBlock as ContentBlock,
type ContentBlockDeltaEvent as ContentBlockDeltaEvent,
+ type ContentBlockParam as ContentBlockParam,
type ContentBlockStartEvent as ContentBlockStartEvent,
type ContentBlockStopEvent as ContentBlockStopEvent,
type ImageBlockParam as ImageBlockParam,
diff --git a/src/resources/index.ts b/src/resources/index.ts
index 4e9653a8..0746ad29 100644
--- a/src/resources/index.ts
+++ b/src/resources/index.ts
@@ -24,6 +24,7 @@ export {
Messages,
type ContentBlock,
type ContentBlockDeltaEvent,
+ type ContentBlockParam,
type ContentBlockStartEvent,
type ContentBlockStopEvent,
type ImageBlockParam,
diff --git a/src/resources/messages.ts b/src/resources/messages.ts
index 3a42b608..54176f00 100644
--- a/src/resources/messages.ts
+++ b/src/resources/messages.ts
@@ -40,6 +40,8 @@ export type ContentBlock = TextBlock | ToolUseBlock;
export type ContentBlockDeltaEvent = RawContentBlockDeltaEvent;
+export type ContentBlockParam = TextBlockParam | ImageBlockParam | ToolUseBlockParam | ToolResultBlockParam;
+
export type ContentBlockStartEvent = RawContentBlockStartEvent;
export type ContentBlockStopEvent = RawContentBlockStopEvent;
@@ -181,7 +183,7 @@ export interface MessageDeltaUsage {
}
export interface MessageParam {
- content: string | Array;
+ content: string | Array;
role: 'user' | 'assistant';
}
@@ -740,6 +742,7 @@ export declare namespace Messages {
export {
type ContentBlock as ContentBlock,
type ContentBlockDeltaEvent as ContentBlockDeltaEvent,
+ type ContentBlockParam as ContentBlockParam,
type ContentBlockStartEvent as ContentBlockStartEvent,
type ContentBlockStopEvent as ContentBlockStopEvent,
type ImageBlockParam as ImageBlockParam,