Skip to content
Merged
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
4 changes: 2 additions & 2 deletions bots/clog/bot.definition.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ export default new sdk.BotDefinition({
typingIndicatorEmoji: false,
botName: 'Clog',
botAvatarUrl: 'https://files.bpcontent.cloud/2025/06/16/20/20250616204038-BRUW6C2R.svg',
createReplyThread: {
enabled: false,
replyBehaviour: {
location: 'channel',
onlyOnBotMention: false,
},
},
Expand Down
4 changes: 4 additions & 0 deletions bots/slackbox/bot.definition.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,5 +38,9 @@ export default new sdk.BotDefinition({
clientSecret: genenv.SLACKBOX_SLACK_CLIENT_SECRET,
signingSecret: genenv.SLACKBOX_SLACK_SIGNING_SECRET,
typingIndicatorEmoji: false,
replyBehaviour: {
location: 'channel',
onlyOnBotMention: false,
},
},
})
2 changes: 1 addition & 1 deletion integrations/anthropic/integration.definition.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export default new IntegrationDefinition({
name: 'anthropic',
title: 'Anthropic',
description: 'Access a curated list of Claude models to set as your chosen LLM.',
version: '12.0.1',
version: '13.0.0',
readme: 'hub.md',
icon: 'icon.svg',
entities: {
Expand Down
43 changes: 0 additions & 43 deletions integrations/anthropic/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ export const ReasoningModelIdReplacements: Partial<Record<ModelId, ModelId>> = {
'claude-haiku-4-5-reasoning-20251001': 'claude-haiku-4-5-20251001',
'claude-sonnet-4-5-reasoning-20250929': 'claude-sonnet-4-5-20250929',
'claude-sonnet-4-reasoning-20250514': 'claude-sonnet-4-20250514',
'claude-3-7-sonnet-reasoning-20250219': 'claude-3-7-sonnet-20250219',
}

const LanguageModels: Record<ModelId, llm.ModelDetails> = {
Expand Down Expand Up @@ -119,48 +118,6 @@ const LanguageModels: Record<ModelId, llm.ModelDetails> = {
maxTokens: 64_000,
},
},
'claude-3-7-sonnet-20250219': {
name: 'Claude 3.7 Sonnet',
description:
'Claude 3.7 Sonnet is an advanced large language model with improved reasoning, coding, and problem-solving capabilities. The model demonstrates notable improvements in coding, particularly in front-end development and full-stack updates, and excels in agentic workflows, where it can autonomously navigate multi-step processes.',
tags: ['agents', 'vision', 'general-purpose', 'coding'],
input: {
costPer1MTokens: 3,
maxTokens: 200_000,
},
output: {
costPer1MTokens: 15,
maxTokens: 64_000,
},
},
'claude-3-7-sonnet-reasoning-20250219': {
name: 'Claude 3.7 Sonnet (Reasoning Mode)',
description:
'This model uses the "Extended Thinking" mode and will use a significantly higher amount of output tokens than the Standard Mode, so this model should only be used for tasks that actually require it.\n\nClaude 3.7 Sonnet is an advanced large language model with improved reasoning, coding, and problem-solving capabilities. The model demonstrates notable improvements in coding, particularly in front-end development and full-stack updates, and excels in agentic workflows, where it can autonomously navigate multi-step processes.',
tags: ['vision', 'reasoning', 'general-purpose', 'agents', 'coding'],
input: {
costPer1MTokens: 3,
maxTokens: 200_000,
},
output: {
costPer1MTokens: 15,
maxTokens: 64_000,
},
},
'claude-3-5-haiku-20241022': {
name: 'Claude 3.5 Haiku',
description:
'Claude 3.5 Haiku features offers enhanced capabilities in speed, coding accuracy, and tool use. Engineered to excel in real-time applications, it delivers quick response times that are essential for dynamic tasks such as chat interactions and immediate coding suggestions. This makes it highly suitable for environments that demand both speed and precision, such as software development, customer service bots, and data management systems.',
tags: ['general-purpose'],
input: {
costPer1MTokens: 0.8,
maxTokens: 200_000,
},
output: {
costPer1MTokens: 4,
maxTokens: 8192,
},
},
'claude-3-5-sonnet-20241022': {
name: 'Claude 3.5 Sonnet (October 2024)',
description:
Expand Down
3 changes: 0 additions & 3 deletions integrations/anthropic/src/schemas.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,6 @@ export const ModelId = z
'claude-sonnet-4-5-reasoning-20250929',
'claude-sonnet-4-20250514',
'claude-sonnet-4-reasoning-20250514',
'claude-3-7-sonnet-20250219',
'claude-3-7-sonnet-reasoning-20250219',
'claude-3-5-haiku-20241022',
'claude-3-5-sonnet-20241022',
'claude-3-5-sonnet-20240620',
'claude-3-haiku-20240307',
Expand Down
2 changes: 1 addition & 1 deletion integrations/messenger/integration.definition.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { actions } from './definitions/actions'
import { messages } from './definitions/channels/channel/messages'

export const INTEGRATION_NAME = 'messenger'
export const INTEGRATION_VERSION = '5.1.3'
export const INTEGRATION_VERSION = '5.1.4'

const commonConfigSchema = z.object({
downloadMedia: z
Expand Down
43 changes: 37 additions & 6 deletions integrations/messenger/src/misc/meta-client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -137,13 +137,17 @@ export class MetaClient {
tokenType: 'none',
})

const scope = dataDebugToken.data.granular_scopes.find(
(item: { scope: string; target_ids: string[] }) => item.scope === 'pages_messaging'
const scope = dataDebugToken.data.granular_scopes?.find(
(item: { scope: string; target_ids?: string[] }) => item.scope === 'pages_messaging'
)

if (scope.target_ids) {
const ids = scope.target_ids
if (!scope?.target_ids?.length) {
return this.getUserManagedPagesFromToken(inputToken)
}

const ids = scope.target_ids

try {
const dataBusinesses = await this._makeRequest({
method: 'GET',
endpoint: `?ids=${ids.join()}&fields=id,name`,
Expand All @@ -154,11 +158,38 @@ export class MetaClient {
})

return Object.keys(dataBusinesses).map((key) => dataBusinesses[key])
} else {
return this.getUserManagedPagesFromToken(inputToken)
} catch (error) {
this._logger?.forBot().warn('Batch page fetch failed for page selection, trying individually, error: ', error)
return this._fetchPagesIndividually(ids, inputToken)
}
}

private async _fetchPagesIndividually(pageIds: string[], userToken: string): Promise<{ id: string; name: string }[]> {
const results: { id: string; name: string }[] = []

await Promise.all(
pageIds.map(async (pageId) => {
try {
const pageData = await this._makeRequest({
method: 'GET',
endpoint: `${pageId}?fields=id,name`,
tokenType: 'none',
customHeaders: {
Authorization: `Bearer ${userToken}`,
},
})
if (pageData.id && pageData.name) {
results.push({ id: pageData.id, name: pageData.name })
}
} catch {
this._logger?.forBot().debug(`Skipping page "${pageId}", failed to get details`)
}
})
)

return results
}

public async getUserManagedPagesFromToken(userToken: string) {
let allPages: { id: string; name: string }[] = []

Expand Down
Loading