DEV Community

Cover image for working with API for the first time
Brian Wangila
Brian Wangila

Posted on

working with API for the first time

last week was project week. I was task with the responsibility of developing a project that uses a public API to perform CRUD operations. This means that the project should create,read, update and delete data from the chosen API. I have to mention that i just started learning JavaScript three weeks ago. However since i had done several crud operations with provided db.json , i was confident that i would have an ample time doing the project. Since i could not find a public API that served the needs of my project idea, i decided to create my own.
The process was smooth and it worked properly until i had to host the API on github. This is when i started getting all kinds of errors. I have too say that it took me a while to realize that my hosting was the problem. Simply because, i could easily fetch data from the API apart from creating and deleting. This means that while debugging, i had ruled in that the hosting is working perfectly. luckily, my dev buddy came to my rescue and informed me that github hosting has some restrictions when it comes to working with APIs. At the moment, am i looking at a site that he recommended for the hosting.

Top comments (0)