decker Posted on Jul 19, 2022 • Edited on Aug 20, 2022 What is the most important rule when designing an API? #api #design #rule #javascript When designing an API for your Application Frontend, what is your rule of thumb? Top comments (8) Subscribe Submit Preview Dismiss Collapse Expand ecyrbe ecyrbe ecyrbe Follow I'm technology enthusiast. I'm interested about all the things related to programming. Location Paris Work Tech Lead Joined Jul 15, 2019 • Jul 19 '22 Dropdown menu Copy link Hide These are some rules i apply that may not suit everyone: share Ideas with your team make sure you design user faced API make distinct APIs for product admins and standard users always design with security in mind design it with separation concern list your expected errors do not handle unwanted use cases because 'maybe it could be used' do not add complexity make it reviewed by another team Collapse Expand Kolja Kolja Kolja Follow Joined Oct 7, 2021 • Jul 19 '22 Dropdown menu Copy link Hide Make it save for ways you dont think about in the first way. Collapse Expand decker decker decker Follow Work Senior Software Developer with a Degree in Computer Science Joined May 27, 2022 • Jul 19 '22 Dropdown menu Copy link Hide Make it functional not technical, because the underlying technic can change more often than the desired function. Collapse Expand Doug Schwartz Doug Schwartz Doug Schwartz Follow Joined Apr 5, 2022 • Jul 19 '22 Dropdown menu Copy link Hide Don't make me think. Collapse Expand Teodor Kulej Teodor Kulej Teodor Kulej Follow Joined Jul 8, 2019 • Jul 20 '22 Dropdown menu Copy link Hide Do one task, and do it right, don't overthink it. If you want a rule that's less verbal and more technical, refer to SOLID principles. Collapse Expand Jonas Pfalzgraf Jonas Pfalzgraf Jonas Pfalzgraf Follow Leisure expert with a passion for madness. Everything you never wanted to know about me: http://linktr.ee/JosunLP SoftwareDeveloper http://ko-fi.com/josunlp Location Norderstedt, Germany Pronouns he/they Work Software Developer Joined May 17, 2021 • Jul 20 '22 Dropdown menu Copy link Hide Use the Open API standard with Swagger to simplify documentation and allow developers and users to work with it in a meaningful way. Collapse Expand Gabriel Cecon Carlsen Gabriel Cecon Carlsen Gabriel Cecon Carlsen Follow Location São Paulo, Brazil Education Computer Science Student at UNESP Presidente Prudente Work FullStack Developer Joined May 5, 2022 • Jul 20 '22 Dropdown menu Copy link Hide Modularity. Each part has its own resposaility (easy to maintain) Code of Conduct • Report abuse
Top comments (8)
These are some rules i apply that may not suit everyone:
Make it save for ways you dont think about in the first way.
Make it functional not technical, because the underlying technic can change more often than the desired function.
Don't make me think.
Do one task, and do it right, don't overthink it.
If you want a rule that's less verbal and more technical, refer to SOLID principles.
Use the Open API standard with Swagger to simplify documentation and allow developers and users to work with it in a meaningful way.
Modularity. Each part has its own resposaility (easy to maintain)