Blockstream Enterprise
ReferenceAPI ReferenceAmp

Issue Amp

Issue Amp.

Request

AmpIssueRequest
interface AmpIssueRequest {
  action: 'add'
  resource: '/amp/assets/issue'
  details: {
    wid: string
    satoshi_asset: number
    satoshi_token: number
    contract: {
      name: string
      ticker: string
      domain: string
      precision: number
      version: number
      issuer_pubkey: string
    }
    utxos: string[]
  }
}

Prop

Type

Response

AmpIssueResponse_success
interface AmpIssueResponse_success {
  status: 'success'
  error_code?: '-1' | '-2' | '-3' | '-4' | '-5' | '-6' | '-7' | '-8' | '-9' | '-10' | '-11' | '-12' | '-13' | undefined
  message?: string | undefined
  details: {
    pset: string
  }
  metadata: unknown
}

Prop

Type

AmpIssueResponse_failed | pending | unauthorized | rejected
interface AmpIssueResponse_failed | pending | unauthorized | rejected {
  status: 'failed' | 'pending' | 'unauthorized' | 'rejected'
  error_code?: '-1' | '-2' | '-3' | '-4' | '-5' | '-6' | '-7' | '-8' | '-9' | '-10' | '-11' | '-12' | '-13' | undefined
  message?: string | undefined
}

Prop

Type

Example

Example
import { AmpActionsSchema } from '@blockstream/amp-js-sdk'
import { broadcastRequest } from './broadcaster'

const response = await broadcastRequest<
  typeof AmpActionsSchema.shape.issue
>(
  {
    action: 'add',
    resource: '/amp/assets/issue',
    details: {
      // TODO: fill in required fields
    },
  },
  blockstream,
)

On this page