ESP32 GET JSON from API - ESP32 GET request from API receive JSON

แชร์
ฝัง
  • เผยแพร่เมื่อ 18 เม.ย. 2019
  • ESP32 get json from api endpoint through wifi, today we will learn how to perform a get request with an esp32 and receive JSON.
    ESP32 wifi: • ESP32 connect to wifi ...
    API: jsonplaceholder.typicode.com/...
    All my code will be available on my Patreon page:
    / 26191735
    www.patreon.com/asali
    Links:
    Sparkfun ESP32 thing
    Affiliate link: amzn.to/2SyQjsm
    Normal link: goo.gl/abAiDf
    Normal ESP32 (cheaper)
    Affiliate link: amzn.to/2GTCHGS
    Normal link: goo.gl/aNXDqi
    Credits:
    Music:
    Classique - Francis Preve
    Thumbnail & video icons:
    Licensed by creativecommons.org/licenses/b...
    Arrow icon by www.flaticon.com/authors/lyolya
    ESP32 icon made by myself

ความคิดเห็น • 28

  • @aakashjana6225
    @aakashjana6225 4 ปีที่แล้ว +8

    After ages, finally there is a crystal clear video explaining how to do this. Now I will be able to get my esp32 out of the box again.

  • @highroyds
    @highroyds 3 ปีที่แล้ว +2

    Thank you for this, it’s given me a more of a understanding of how and what happens, but wow you’re quick with copy and paste then going to the next step. I’m thankful for the pause and play on the vid lol.

  • @junghanshin7193
    @junghanshin7193 3 ปีที่แล้ว +1

    Simple and clear. Big help. Thank you.

  • @hansad.k6273
    @hansad.k6273 3 ปีที่แล้ว

    Bless you bro

  • @jagathesvarma1872
    @jagathesvarma1872 4 ปีที่แล้ว

    Thank You so much sir. Is there any way to send the data to firebase ? For DH11 + ESP32 + Firebase
    Im trying to figure it out for days but no luck.

  • @yousefalhelabi8601
    @yousefalhelabi8601 ปีที่แล้ว +1

    What is the random function used for ?

  • @Blink-ut7uh
    @Blink-ut7uh 2 ปีที่แล้ว

    What is the use of the long rnd variable? Why is it added at the end of the web address

  • @EpsRae
    @EpsRae 3 ปีที่แล้ว

    Hi great video! can you explain how to add headers to the GET request?

  • @gilangrakaramadhan7199
    @gilangrakaramadhan7199 5 หลายเดือนก่อน

    Thanks ❤

  • @franklarsen6753
    @franklarsen6753 ปีที่แล้ว

    Great video. Can you also show how it works if I have more than one dataset in JSON file?

  • @WistrelChianti
    @WistrelChianti 3 ปีที่แล้ว

    Interesting library there... I'm wondering how it deals with arrays. Will take a look.

  • @niltonschumacherfilho3368
    @niltonschumacherfilho3368 4 ปีที่แล้ว

    Hey, I'm working on a project that needs to get data from my page on my website. But I came across a problem. When I do the GET command on my page I get this:
    Statuscode: 200



    Array
    (
    [0] => stdClass Object
    (
    [AutoIncrement] => 1
    [Nome Aparelho] => LED
    [Status] => 0
    )
    )

    This is when I output the page info:
    0.00
    0
    Could you help me please?

  • @Staxel_aran
    @Staxel_aran 4 ปีที่แล้ว

    Aaaaawsoooom dude you help me so much

  • @engineerlawalhamzatademola4267
    @engineerlawalhamzatademola4267 ปีที่แล้ว

    The link to the code is not working 😔

  • @pavan4032
    @pavan4032 4 ปีที่แล้ว

    Hi sir, great video
    Can you please make a video on
    PUT , POST , Requests to hosted phpmyadmin
    Json API end point
    Thank you

  • @andrewmcallister3529
    @andrewmcallister3529 3 ปีที่แล้ว +2

    Good video, but what about JSON that's more than 1 dimensional?

    • @tf1044
      @tf1044 3 ปีที่แล้ว

      if you find out can you tell me here?

    • @andrewmcallister3529
      @andrewmcallister3529 3 ปีที่แล้ว +2

      @@tf1044 Figured it out, you just add more square brackets after like:
      ["daily"]["weather"]["rainfall"]

  • @Blink-ut7uh
    @Blink-ut7uh 2 ปีที่แล้ว

    What if status code is 404? That's greater than 0 but is a resulting error

  • @saagembhobbyiest5259
    @saagembhobbyiest5259 3 ปีที่แล้ว

    i am trying to use this example with my url but getting the response as 200 only. I am not getting json data after that.

    • @babygreen17
      @babygreen17 2 ปีที่แล้ว

      same

    • @slutbit1749
      @slutbit1749 2 ปีที่แล้ว +2

      json-results are only defined for rnd=0-5, when rnd is 6-10 it returns [ ].

  • @mustafakurdi7554
    @mustafakurdi7554 4 ปีที่แล้ว

    Please need the Arduino Json Library 😥
    thanks❤

  • @vantasy5335
    @vantasy5335 5 ปีที่แล้ว

    What is JSON?

    • @abobija
      @abobija 4 ปีที่แล้ว +1

      JSON is just standardized format for textual data representation. Something like XML. You can google it - there is a plenty of information about JSON and other data formats on internet.