Python Flask Starter

Поділитися
Вставка
  • Опубліковано 15 жов 2024
  • In this edition of Stripe Developer Office Hours, follow along as CJ Avilla walks through the fundamentals of Python and Flask.
    Resources
    Flask web framework flask.palletsp...
    curl command line tool curl.haxx.se/
    python-dotenv pypi.org/proje...
    Stripe Webhooks Guide stripe.com/doc...
    Stripe Event Types stripe.com/doc...
    Code: github.com/str...
    Table of contents
    02:17 Install starter with Stripe CLI
    03:10 Setup directory structure
    03:24 Basic HTML
    05:05 Install dependencies with pip
    06:09 Start a basic server.py
    08:42 Add GET routes to the server
    14:04 Make GET request from client
    18:04 Add POST route to the server
    22:20 Make POST request from client
    27:27 Add basic webhook handler
    Presenter
    CJ Avilla, Developer Advocate at Stripe - / cjav_dev
    Support
    If you have a question, please feel free to reach out to our support team on Discord at stripe.com/go/....
    Updates
    Sign up to stay updated with developer news: go.stripe.glob...
    Feedback
    If you have any feedback about this or other episodes, let us know: forms.gle/VjNq....
    #Stripe #Payments

КОМЕНТАРІ • 20

  • @roymath
    @roymath 4 роки тому +1

    Nicely done. I like the way you built it up from a very minimal place to something truly functional. You might want to run flask in “watch” mode to avoid stopping and restarting the server

  • @WhiteLens
    @WhiteLens 4 роки тому +8

    Wondering if you can cover Django as well

  • @IsaiahBaker
    @IsaiahBaker 4 роки тому +2

    This was beyond helpful. Thank you sir.

    • @cjav_dev
      @cjav_dev 4 роки тому +1

      Happy to help!

  • @keyntankeye
    @keyntankeye 2 роки тому

    thanks for the video. what plugin do you have for your vim to have the sidebar?

    • @StripeDev
      @StripeDev  2 роки тому

      Hey there-the plugin is called NERDTree 😊

  • @DevuniSuvaartha
    @DevuniSuvaartha 4 роки тому +1

    Can you share the code please

  • @my5cents4u
    @my5cents4u 3 роки тому

    Where to START??? Seems to be a never ending new beginning of a long list of programs! I just want to implement a checkout payment button on an HTML page but drowning in confusion and code!

  • @AgrumeFramboise
    @AgrumeFramboise 3 роки тому

    Thank you so much, this content is very pleasant to follow and helpful 🙏

  • @mxd8
    @mxd8 Рік тому

    I hope stripe is compatible with a lower version of flask such as FLASK==1.2.0

    • @StripeDev
      @StripeDev  Рік тому +1

      Hi Michael-Stripe has no specific dependency with Flask, so you can use older versions of Flask if you're integrating Stripe yourself. Our Stripe-Python library will work in any cases.

    • @mxd8
      @mxd8 Рік тому

      @@StripeDev Awesome, I'm going to test and follow up!

  • @JohnWiltshireIreland
    @JohnWiltshireIreland 4 роки тому

    Awesome tutorial. Instead of using the get keys fetch call, could you not have passed the key into the template as a variable to the template using Jinja variables? Are there advantages to doing it with fetch?
    Do you have a demo for where somebody would fill out an order form and then make the payment and only after a successful payment would you insert the form data to a database using flask?

    • @StripeDev
      @StripeDev  4 роки тому +1

      You could embed with Jinja variables, that's a great option. This was mostly showing how to make an AJAX call to the server. We have a number of demos for taking payment, but I'm not sure if we have one that matches that exact use-case.

  • @zakchips
    @zakchips 4 роки тому

    Very useful to start with.

  • @howardsakala8868
    @howardsakala8868 4 роки тому

    I have noticed you copied env (cp ~/.env .) when i try that, I'm getting an error. Can you please advise on how to get around this error

    • @JeanAlesiagain3
      @JeanAlesiagain3 3 роки тому

      do you have .env in your home directory? Are you using a mac?

    • @howardsakala8868
      @howardsakala8868 3 роки тому

      @@JeanAlesiagain3 The issue was resolved, thank you. I'm using Ubuntu Linux

  • @JeanAlesiagain3
    @JeanAlesiagain3 3 роки тому +1

    I'm sorry. This tutorial teaches very little about stripe.
    It is mostly about teaching beginner web development skills.
    Please make a video teaching stripe's core concepts (such what a payment intent is) and common use cases (how to manage sessions)

    • @my5cents4u
      @my5cents4u 3 роки тому

      yes! Stripe is the most confusing integration I have ever encountered in my 15 years on the web! A billion dollar company catching up with PayPal and they can not afford to have understandable tutorials? In two weeks of attempt with their lame tech support which is only a sales department they gave me links to pay programmers for Stripe! PATHETIC!