AI Agents & MCPs & AI Workflow Automation • (~400 MCP servers for AI agents) • AI Automation / AI Agent with MCPs • AI Workflows & AI Agents • MCPs for AI Agents
TypeScript ai-agentai-agent-toolsai-agentsai-agents-frameworkmcpmcp-servermcp-toolsmcpsn8n-alternativeno-code-automationworkflowworkflow-automationworkflows
import { createAction, PieceAuth, Property } from '@activepieces/pieces-framework';
import { httpClient, HttpMethod } from '@activepieces/pieces-common';
import { MEMPOOL_API_BASE_URL } from '../../common';
export const getTransactionHex = createAction({
auth:PieceAuth.None(),
name: 'get_transaction_hex',
displayName: 'Get Transaction Hex',
description: 'Get the raw transaction in hex format',
audience: 'both',
aiMetadata: { description: 'Fetch the hex-encoded serialized form of a transaction by its transaction ID from the /hex endpoint. Functionally equivalent to Get Raw Transaction; use Get Transaction instead for parsed/structured detail. Read-only.', idempotent: true },
// category: 'Transactions',
props: {
txid: Property.ShortText({
displayName: 'Transaction ID',
description: 'The transaction ID to get hex data for',
required: true,
}),
},
async run({ propsValue }) {
const response = await httpClient.sendRequest({
method: HttpMethod.GET,
url: `${MEMPOOL_API_BASE_URL}/api/tx/${propsValue.txid}/hex`,
});
return response.body;
},
});