Giter Club home page Giter Club logo

pump_fun_py's Introduction

pump_fun_py

Python library to trade on pump.fun.

If you can - please support my work and donate to: 3pPK76GL5ChVFBHND54UfBMtg36Bsh1mzbQPTbcK89PD

Swap Layout

Do not change the hard-coded values as they are part of the actual swap instructions for the pump.fun program.

discriminator_as_int = 16927863322537952870

discriminator_as_int = 12502976635542562355

To see for yourself, decode the "Instruction Raw Data" from any pump fun transaction using the find_instruction.py.

Contact

My services are for hire. Contact me if you need help integrating the code into your own project.

Telegram: Allen_A_Taylor (AL THE BOT FATHER)

FAQS

What format should my private key be in?

The private key should be in the base58 string format, not bytes.

Why are my transactions being dropped?

You get what you pay for. If you use the public RPC, you're going to get rekt. Spend the money for Helius or Quick Node. Also, play around with the compute limits and lamports.

What format is slippage in?

Slippage is in decimal format. Example: .05 slippage is 5%.

Example

from pump_fun import buy

#PUMP FUN MINT ADDRESS (NOT RAYDIUM)
mint_str = "token_to_buy"

#BUY
buy(mint_str=mint_str, sol_in=.1, slippage_decimal=.25)

from pump_fun import sell
from utils import get_token_balance

#PUMP FUN MINT ADDRESS (NOT RAYDIUM)
mint_str = "token_to_sell"

#SELL
token_balance = get_token_balance(mint_str)
sell(mint_str=mint_str, token_balance=token_balance, slippage_decimal=.25)

pump_fun_py's People

Contributors

allen-taylor avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.