Skip to content

Instantly share code, notes, and snippets.

View Rahat-ch's full-sized avatar
:electron:
Coding, Speaking, Writing, Rapping

Rahat Chowdhury Rahat-ch

:electron:
Coding, Speaking, Writing, Rapping
View GitHub Profile
import { AccountAddress, Aptos, AptosConfig, Network } from "@aptos-labs/ts-sdk"
const config = new AptosConfig({
network: Network.TESTNET,
fullnode: 'https://testnet.movementnetwork.xyz/v1',
faucet: 'https://faucet.testnet.movementnetwork.xyz/',
indexer: 'https://indexer.testnet.movementnetwork.xyz/v1/graphql',
});
const aptos = new Aptos(config);
import { Character, ModelProviderName, defaultCharacter, Clients } from "@elizaos/core";
export const mainCharacter: Character = {
...defaultCharacter,
clients: [Clients.TWITTER],
modelProvider: ModelProviderName.GAIANET,
name: "Unjeet",
"bio": [
"Unjeet is a 22-year-old South Asian man who left his promising career in medicine to pursue a greater calling: helping people recover from crypto scams. Armed with his analytical mind and a deep understanding of blockchain technology, he's made it his mission to educate and safeguard others from fraudulent crypto schemes while making them and himself some money.",
"He understands the importance of figures like Molly White and has deep respect for her work, but he believes he can destroy the jeets of the world.",
import {
Aptos,
AptosConfig,
Network,
Account,
Ed25519PrivateKey,
AccountAddress,
} from "@aptos-labs/ts-sdk";
import * as fs from "fs/promises";
import * as path from "path";
[09:04:43.385] Running build in Washington, D.C., USA (East) – iad1
[09:04:43.490] Cloning github.com/movementlabsxyz/movement-docs (Branch: main, Commit: d60486c)
[09:04:44.610] Cloning completed: 1.120s
[09:04:51.172] Skipping build cache since Package Manager changed from "npm" to "pnpm"
[09:04:54.038] Running "vercel build"
[09:04:55.081] Vercel CLI 37.4.2
[09:04:56.168] Warning: Detected "engines": { "node": ">=18.0" } in your `package.json` that will automatically upgrade when a new major Node.js Version is released. Learn More: http://vercel.link/node-version
[09:04:56.206] Detected `pnpm-lock.yaml` version 9 generated by pnpm@9.x
[09:04:56.234] Installing dependencies...
[09:04:56.824] Lockfile is up to date, resolution step is skipped
const {
Account,
Aptos,
AptosConfig,
Network,
MoveString,
generateRawTransaction,
SimpleTransaction,
generateTransactionPayload,
Ed25519PrivateKey
const { Account, Aptos, AptosConfig, Network, Ed25519PrivateKey } = require("@aptos-labs/ts-sdk");
// Define the custom network configuration
const config = new AptosConfig({
network: Network.CUSTOM,
fullnode: 'https://aptos.testnet.suzuka.movementlabs.xyz/v1',
faucet: 'https://faucet.testnet.suzuka.movementlabs.xyz',
});
// Define the module address and functions
const { Aptos, AptosConfig, Network, CustomChainId } = require("@aptos-labs/ts-sdk");
const config = new AptosConfig({
network: Network.CUSTOM,
fullnode: 'https://aptos.testnet.suzuka.movementlabs.xyz/v1',
faucet: 'https://faucet.testnet.suzuka.movementlabs.xyz/',
});
const aptos = new Aptos(config);
const handleDeposit = async (e: React.FormEvent<HTMLFormElement>) => {
e.preventDefault();
if (smartAccount === null) return
const approvalTrx = tokenContract.populateTransaction.approve(
allowanceContract.address,
10
);
const depositTrx = allowanceContract.populateTransaction.deposit(10);
const userOp = await smartAccount.buildUserOp([approvalTrx, depositTrx]);
try {
import { config } from "dotenv"
import { IBundler, Bundler } from '@biconomy/bundler'
import { BiconomySmartAccountV2, DEFAULT_ENTRYPOINT_ADDRESS } from "@biconomy/account"
import { ethers } from 'ethers'
import { ChainId } from "@biconomy/core-types"
import { ECDSAOwnershipValidationModule, DEFAULT_ECDSA_OWNERSHIP_MODULE } from "@biconomy/modules";
config()
const bundler: IBundler = new Bundler({
import Head from 'next/head'
import styles from '@/styles/Home.module.css'
import { LitNodeClient } from "@lit-protocol/lit-node-client";
import { LitAbility, LitActionResource } from "@lit-protocol/auth-helpers";
import { AuthCallbackParams } from "@lit-protocol/types";
import { PKPEthersWallet } from "@lit-protocol/pkp-ethers";
const PKP_PUBLIC_KEY = "0x044fa8adc71d068e070fd3d2e04eb19620187c920ad3ab2cccb1dc3d15e5306099e45d4bd2bf185eeeca79cface8036f32858e7e5c808861c910887be67f5811f3"
export default function Home() {