call createTransaction directly from login-server

This commit is contained in:
einhornimmond 2021-08-05 14:54:40 +02:00
parent 40dbcb6a92
commit afdf112a9c

View File

@ -23,12 +23,14 @@ export class TransactionResolver {
): Promise<string> {
const payload = {
session_id: sessionId,
email,
target_email: email,
amount,
memo,
auto_sign: true,
transaction_type: 'transfer',
blockchain_type: 'mysql'
}
const result = await apiPost(CONFIG.COMMUNITY_API_URL + 'sendCoins', payload)
const result = await apiPost(CONFIG.LOGIN_API_URL + 'createTransaction', payload)
if (!result.success) {
throw new Error(result.data)
}