Add Activepieces integration for workflow automation
- Add Activepieces fork with SmoothSchedule custom piece - Create integrations app with Activepieces service layer - Add embed token endpoint for iframe integration - Create Automations page with embedded workflow builder - Add sidebar visibility fix for embed mode - Add list inactive customers endpoint to Public API - Include SmoothSchedule triggers: event created/updated/cancelled - Include SmoothSchedule actions: create/update/cancel events, list resources/services/customers 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"Fetch the price of a crypto pair from Binance": "Rufe den Preis eines Krypto-Paares aus Binanz ab",
|
||||
"Fetch Pair Price": "Paarpreis abrufen",
|
||||
"Fetch the current price of a pair (e.g. BTC/USDT)": "Holen Sie den aktuellen Preis eines Paares (z.B. BTC/USDT)",
|
||||
"First Coin Symbol": "Erstes Münzsymbol",
|
||||
"Second Coin Symbol": "Zweites Münzsymbol",
|
||||
"The currency to fetch the price for (e.g. 'BTC' in 'BTC/USDT')": "Die Währung, für die der Preis abgerufen wird (z.B. 'BTC' in 'BTC/USDT')",
|
||||
"The currency to fetch the price in (e.g. 'USDT' in 'BTC/USDT')": "Die Währung, in der der Preis abgerufen wird (z.B. 'USDT' in 'BTC/USDT')"
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"Fetch the price of a crypto pair from Binance": "Obtener el precio de un par de criptomonedas de Binance",
|
||||
"Fetch Pair Price": "Obtener precio de par",
|
||||
"Fetch the current price of a pair (e.g. BTC/USDT)": "Obtener el precio actual de un par (ej. BTC/USDT)",
|
||||
"First Coin Symbol": "Primer símbolo de moneda",
|
||||
"Second Coin Symbol": "Segundo símbolo de moneda",
|
||||
"The currency to fetch the price for (e.g. 'BTC' in 'BTC/USDT')": "La moneda para obtener el precio (por ejemplo, 'BTC' en 'BTC/USDT')",
|
||||
"The currency to fetch the price in (e.g. 'USDT' in 'BTC/USDT')": "La moneda en la que obtener el precio (por ejemplo, 'USDT' en 'BTC/USDT')"
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"Fetch the price of a crypto pair from Binance": "Récupérer le prix d'une paire de cryptomonnaies de Binance",
|
||||
"Fetch Pair Price": "Récupérer le prix de la paire",
|
||||
"Fetch the current price of a pair (e.g. BTC/USDT)": "Récupérer le prix actuel d'une paire (par exemple BTC/USDT)",
|
||||
"First Coin Symbol": "Premier Symbole de Pièce",
|
||||
"Second Coin Symbol": "Second Symbole de Pièce",
|
||||
"The currency to fetch the price for (e.g. 'BTC' in 'BTC/USDT')": "La devise pour laquelle récupérer le prix (par exemple 'BTC' dans 'BTC/USDT')",
|
||||
"The currency to fetch the price in (e.g. 'USDT' in 'BTC/USDT')": "La devise dans laquelle récupérer le prix (ex: 'USDT' en 'BTC/USDT')"
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"Fetch the price of a crypto pair from Binance": "Binanceから暗号ペアの価格を取得",
|
||||
"Fetch Pair Price": "ペア価格を取得",
|
||||
"Fetch the current price of a pair (e.g. BTC/USDT)": "ペアの現在の価格を取得します (例: BTC / USDT)",
|
||||
"First Coin Symbol": "最初のコインシンボル",
|
||||
"Second Coin Symbol": "2番目のコインシンボル",
|
||||
"The currency to fetch the price for (e.g. 'BTC' in 'BTC/USDT')": "価格を取得する通貨 (例: 'BTC' in 'BTC / USDT')",
|
||||
"The currency to fetch the price in (e.g. 'USDT' in 'BTC/USDT')": "価格を取得する通貨(例:'BTC/USDT')"
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"Fetch the price of a crypto pair from Binance": "De prijs van een crypto-paar ophalen van Binance",
|
||||
"Fetch Pair Price": "Pakket Pair Prijs",
|
||||
"Fetch the current price of a pair (e.g. BTC/USDT)": "Ophalen van de huidige prijs van een paar (bijvoorbeeld BTC/USDT)",
|
||||
"First Coin Symbol": "Eerste Munt Symbool",
|
||||
"Second Coin Symbol": "Tweede Munt Symbool",
|
||||
"The currency to fetch the price for (e.g. 'BTC' in 'BTC/USDT')": "De valuta om de prijs van (bijvoorbeeld 'BTC' in 'BTC/USDT') op te halen",
|
||||
"The currency to fetch the price in (e.g. 'USDT' in 'BTC/USDT')": "De valuta om de prijs op te halen (bijvoorbeeld 'USDT' in 'BTC/USDT')"
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"Fetch the price of a crypto pair from Binance": "Obter o preço de um par de criptomoedas da Binance",
|
||||
"Fetch Pair Price": "Buscar Preço do Par",
|
||||
"Fetch the current price of a pair (e.g. BTC/USDT)": "Buscar o preço atual de um par (por exemplo, BTC/USDT)",
|
||||
"First Coin Symbol": "Símbolo da Primeira Moeda",
|
||||
"Second Coin Symbol": "Símbolo da Segunda Moeda",
|
||||
"The currency to fetch the price for (e.g. 'BTC' in 'BTC/USDT')": "A moeda para buscar o preço (por exemplo, 'BTC' em 'BTC/USDT')",
|
||||
"The currency to fetch the price in (e.g. 'USDT' in 'BTC/USDT')": "A moeda para buscar o preço (por exemplo, 'USDT' em 'BTC/USDT')"
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
{
|
||||
"Binance": "Бинанс",
|
||||
"Fetch the price of a crypto pair from Binance": "Получить цену пары криптовалют с Binance",
|
||||
"Fetch Pair Price": "Получить цену на пару",
|
||||
"Fetch the current price of a pair (e.g. BTC/USDT)": "Получить текущую цену пары (например, BTC/USDT)",
|
||||
"First Coin Symbol": "Символ первой монеты",
|
||||
"Second Coin Symbol": "Вторая монета",
|
||||
"The currency to fetch the price for (e.g. 'BTC' in 'BTC/USDT')": "Валюта для получения цены (например, 'BTC' в 'BTC/USDT')",
|
||||
"The currency to fetch the price in (e.g. 'USDT' in 'BTC/USDT')": "Валюта для получения цены (например 'USDT' в 'BTC/USDT')"
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"Fetch the price of a crypto pair from Binance": "Fetch the price of a crypto pair from Binance",
|
||||
"Fetch Pair Price": "Fetch Pair Price",
|
||||
"Fetch the current price of a pair (e.g. BTC/USDT)": "Fetch the current price of a pair (e.g. BTC/USDT)",
|
||||
"First Coin Symbol": "First Coin Symbol",
|
||||
"Second Coin Symbol": "Second Coin Symbol",
|
||||
"The currency to fetch the price for (e.g. 'BTC' in 'BTC/USDT')": "The currency to fetch the price for (e.g. 'BTC' in 'BTC/USDT')",
|
||||
"The currency to fetch the price in (e.g. 'USDT' in 'BTC/USDT')": "The currency to fetch the price in (e.g. 'USDT' in 'BTC/USDT')"
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
{
|
||||
"Binance": "Binance",
|
||||
"Fetch the price of a crypto pair from Binance": "Fetch the price of a crypto pair from Binance",
|
||||
"Fetch Pair Price": "Fetch Pair Price",
|
||||
"Fetch the current price of a pair (e.g. BTC/USDT)": "Fetch the current price of a pair (e.g. BTC/USDT)",
|
||||
"First Coin Symbol": "First Coin Symbol",
|
||||
"Second Coin Symbol": "Second Coin Symbol",
|
||||
"The currency to fetch the price for (e.g. 'BTC' in 'BTC/USDT')": "The currency to fetch the price for (e.g. 'BTC' in 'BTC/USDT')",
|
||||
"The currency to fetch the price in (e.g. 'USDT' in 'BTC/USDT')": "The currency to fetch the price in (e.g. 'USDT' in 'BTC/USDT')"
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"Fetch the price of a crypto pair from Binance": "Fetch the price of a crypto pair from Binance",
|
||||
"Fetch Pair Price": "Fetch Pair Price",
|
||||
"Fetch the current price of a pair (e.g. BTC/USDT)": "Fetch the current price of a pair (e.g. BTC/USDT)",
|
||||
"First Coin Symbol": "First Coin Symbol",
|
||||
"Second Coin Symbol": "Second Coin Symbol",
|
||||
"The currency to fetch the price for (e.g. 'BTC' in 'BTC/USDT')": "The currency to fetch the price for (e.g. 'BTC' in 'BTC/USDT')",
|
||||
"The currency to fetch the price in (e.g. 'USDT' in 'BTC/USDT')": "The currency to fetch the price in (e.g. 'USDT' in 'BTC/USDT')"
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
import { PieceAuth, createPiece } from '@activepieces/pieces-framework';
|
||||
import { fetchCryptoPairPrice } from './lib/actions/fetch-pair-price';
|
||||
|
||||
export const binance = createPiece({
|
||||
displayName: 'Binance',
|
||||
description: 'Fetch the price of a crypto pair from Binance',
|
||||
minimumSupportedRelease: '0.30.0',
|
||||
logoUrl: 'https://cdn.activepieces.com/pieces/binance.png',
|
||||
categories: [],
|
||||
auth: PieceAuth.None(),
|
||||
actions: [fetchCryptoPairPrice],
|
||||
authors: ["kishanprmr","khaledmashaly","abuaboud"],
|
||||
triggers: [],
|
||||
});
|
||||
@@ -0,0 +1,49 @@
|
||||
import { httpClient, HttpMethod } from '@activepieces/pieces-common';
|
||||
import { createAction, Property } from '@activepieces/pieces-framework';
|
||||
|
||||
export const fetchCryptoPairPrice = createAction({
|
||||
name: 'fetch_crypto_pair_price',
|
||||
displayName: 'Fetch Pair Price',
|
||||
description: 'Fetch the current price of a pair (e.g. BTC/USDT)',
|
||||
props: {
|
||||
first_coin: Property.ShortText({
|
||||
displayName: 'First Coin Symbol',
|
||||
description:
|
||||
"The currency to fetch the price for (e.g. 'BTC' in 'BTC/USDT')",
|
||||
required: true,
|
||||
}),
|
||||
second_coin: Property.ShortText({
|
||||
displayName: 'Second Coin Symbol',
|
||||
description:
|
||||
"The currency to fetch the price in (e.g. 'USDT' in 'BTC/USDT')",
|
||||
required: true,
|
||||
}),
|
||||
},
|
||||
async run(context) {
|
||||
const { first_coin, second_coin } = context.propsValue;
|
||||
if (first_coin && second_coin)
|
||||
return await fetchCryptoPairPriceImpl(`${first_coin}${second_coin}`);
|
||||
throw Error('Missing parameter(s)');
|
||||
},
|
||||
});
|
||||
|
||||
async function fetchCryptoPairPriceImpl(symbol: string): Promise<number> {
|
||||
const formattedSymbol = symbol
|
||||
.replace('/', '')
|
||||
.replace(' ', '')
|
||||
.toUpperCase();
|
||||
|
||||
const url = `https://api.binance.com/api/v3/ticker/price?symbol=${formattedSymbol}`;
|
||||
|
||||
try {
|
||||
const response = await httpClient.sendRequest({
|
||||
method: HttpMethod.GET,
|
||||
url,
|
||||
});
|
||||
const data = await response.body;
|
||||
return Number(data['price']);
|
||||
} catch (error) {
|
||||
console.error(`Error fetching price for symbol ${symbol}:`, error);
|
||||
throw error;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user