Skip to content

Clarify: internal() message creator is in @ton/core, not @ton/ton #145

@spendollars

Description

@spendollars

Problem

When building TON applications that need to send internal messages, developers often import internal() from the wrong package.

The function is only available in @ton/core:

// ✅ CORRECT
import { internal } from '@ton/core';

// ❌ WRONG — internal() does not exist here
import { internal } from '@ton/ton';

This causes a runtime error like TypeError: internal is not a function which is confusing because @ton/ton depends on @ton/core and re-exports many things.

Proposed Fix

Add a note in the @ton/ton README or JSDoc pointing to @ton/core for message creation utilities, or re-export internal from @ton/ton for convenience.

Context

This is a common pain point for developers building Telegram bots and platforms on TON. I encountered this while building TON Agent Platform, and the confusion cost significant debugging time.

Packages

  • @ton/ton ^14
  • @ton/core ^0.57

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions