{"id":8074,"date":"2024-07-17T22:51:55","date_gmt":"2024-07-17T17:21:55","guid":{"rendered":"https:\/\/pheonixsolutions.com\/blog\/?p=8074"},"modified":"2024-07-25T02:06:37","modified_gmt":"2024-07-24T20:36:37","slug":"1-apis","status":"publish","type":"post","link":"https:\/\/pheonixsolutions.com\/blog\/1-apis\/","title":{"rendered":"1. APIs"},"content":{"rendered":"\n<p>API Stands for Application Programming Interface. APIs have a set of rules that allow different software applications to communicate with each other, generally letting them exchange data and perform operations simultaneously.<br>APIs are important because they allow different software systems to work together, combining their functionalities. They help developers to create new applications quickly by using existing APIs, so we don&#8217;t have to start from scratch. While Learning APIs we need some basic knowledge of HTTP.<\/p>\n\n\n\n<p><strong><em>HTTP(Hypertext Transfer Protocol) : <\/em><\/strong><\/p>\n\n\n\n<p>HTTP is the most common protocol used to access APIs on web. Http serves as the communication between Client and Server where the API hosted. It involves making HTTP requests and receiving HTTP responses.<\/p>\n\n\n\n<p><strong><em>HTTP Requests: <\/em><\/strong> Application sends requests to API Server. This Request includes below methods to perform action, along with any necessary data or parameters : <br>1. GET&#8211;&gt; Retrive data from server<br>2. POST &#8211;&gt; Sends new request to server<br>3. PUT &#8211;&gt; Updates the existing data on the server<br>4. DELETE &#8211;&gt; delete data from the server<br><br><strong><em>HTTP Response:<\/em><\/strong> API Server process the request and send back an response. This response includes status code indicating the result:<br>Ex:<br>1. 200 for success<br>2. 404 for not found<br>3. 500 for Internal server error<br><br><strong><em>Different Types of APIs:<\/em><\/strong><br>1. REST(Representational State Transfer) APIs<br>2. SOAP(Simple Object Access Protocol) APIs<br>3. GraphQL APIs<br>4. gRPC (gRPC Remote Procedure Calls) APIs<\/p>\n\n\n\n<p><strong><em>REST APIs:  <\/em><\/strong>REST APIs uses HTTP Methods (GET,POST,UPDATE,DELETE) to intract with resources. Its having Multiple endpoints. With each endpoint corresponding to a different functionality.<br>EX:  http:\/\/localhost:3000\/products<\/p>\n\n\n\n<p><strong><em>GraphQL APIs:<\/em><\/strong> GraphQL is a query language  for APIs that allows requesting exactly the data needed from a server. It uses a single endpoint, making it efficient and flexible for both developers and clients.<br><strong><em>Queries<\/em><\/strong> and <strong><em>Mutations<\/em><\/strong> are used for data request and responses in Graphql.<br>EX:  http:\/\/localhost:3000\/graphql<br><br><strong><em>Queries: <\/em><\/strong>Fetch the data from server, It allows specifying the exact data needed and returns that data in the response.<br>Ex: <br><strong>query<\/strong>\u00a0GetAllUsers\u00a0{\u00a0\u00a0<br>          getAllUsers\u00a0{<br>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0          \u00a0id\u00a0\u00a0\u00a0<br>                  user_name<br>\u00a0\u00a0\u00a0        \u00a0}<br>       }<br><strong><em>Mutations:<\/em><\/strong> Used to modify or update data on the server, such as creating, updating, or deleting data.<br>Ex:<br>mutation AddUser {<br>addUser(user_name: &#8220;John&#8221;) {<br>message<br>user {<br>id<br>user_name<br>}<br>}<br>}<br><br><br><br><\/p>\n","protected":false},"excerpt":{"rendered":"<p>API Stands for Application Programming Interface. APIs have a set of rules that allow different software applications to communicate with each other, generally letting them exchange data and perform operations simultaneously.APIs are important because they allow different software systems to work together, combining their functionalities. They help developers to create&hellip; <a href=\"https:\/\/pheonixsolutions.com\/blog\/1-apis\/\" class=\"more-link read-more\" rel=\"bookmark\">Continue Reading <span class=\"screen-reader-text\">1. APIs<\/span><i class=\"fa fa-arrow-right\"><\/i><\/a><\/p>\n","protected":false},"author":501,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[1],"tags":[],"class_list":{"0":"post-8074","1":"post","2":"type-post","3":"status-publish","4":"format-standard","5":"hentry","6":"category-uncategorized","7":"h-entry","9":"h-as-article"},"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Pheonix Solutions - We Empower Your Business Growth<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/pheonixsolutions.com\/blog\/1-apis\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Pheonix Solutions - We Empower Your Business Growth\" \/>\n<meta property=\"og:description\" content=\"API Stands for Application Programming Interface. APIs have a set of rules that allow different software applications to communicate with each other, generally letting them exchange data and perform operations simultaneously.APIs are important because they allow different software systems to work together, combining their functionalities. They help developers to create&hellip; Continue Reading 1. APIs\" \/>\n<meta property=\"og:url\" content=\"https:\/\/pheonixsolutions.com\/blog\/1-apis\/\" \/>\n<meta property=\"og:site_name\" content=\"PHEONIXSOLUTIONS\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/PheonixSolutions-209942982759387\/\" \/>\n<meta property=\"article:published_time\" content=\"2024-07-17T17:21:55+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-07-24T20:36:37+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2016\/09\/PX2.png\" \/>\n\t<meta property=\"og:image:width\" content=\"3837\" \/>\n\t<meta property=\"og:image:height\" content=\"2540\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"mounika\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@pheonixsolution\" \/>\n<meta name=\"twitter:site\" content=\"@pheonixsolution\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"mounika\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/1-apis\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/1-apis\\\/\"},\"author\":{\"name\":\"mounika\",\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/#\\\/schema\\\/person\\\/01d9ea3b8083c6d2fbabebbbb9f6ec9b\"},\"headline\":\"1. APIs\",\"datePublished\":\"2024-07-17T17:21:55+00:00\",\"dateModified\":\"2024-07-24T20:36:37+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/1-apis\\\/\"},\"wordCount\":358,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/#organization\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/1-apis\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/1-apis\\\/\",\"url\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/1-apis\\\/\",\"name\":\"Pheonix Solutions - We Empower Your Business Growth\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/#website\"},\"datePublished\":\"2024-07-17T17:21:55+00:00\",\"dateModified\":\"2024-07-24T20:36:37+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/1-apis\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/1-apis\\\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/1-apis\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"1. APIs\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/\",\"name\":\"Pheonix Solutions\",\"description\":\"We Empower Your Business Growth\",\"publisher\":{\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/#organization\",\"name\":\"PheonixSolutions\",\"url\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/wp-content\\\/uploads\\\/2016\\\/12\\\/logo.png\",\"contentUrl\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/wp-content\\\/uploads\\\/2016\\\/12\\\/logo.png\",\"width\":454,\"height\":300,\"caption\":\"PheonixSolutions\"},\"image\":{\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/www.facebook.com\\\/PheonixSolutions-209942982759387\\\/\",\"https:\\\/\\\/x.com\\\/pheonixsolution\"]},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/#\\\/schema\\\/person\\\/01d9ea3b8083c6d2fbabebbbb9f6ec9b\",\"name\":\"mounika\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/649da26ffd31b2ac850b80549fed038175a6ce33673b3389595178d5c3a31936?s=96&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/649da26ffd31b2ac850b80549fed038175a6ce33673b3389595178d5c3a31936?s=96&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/649da26ffd31b2ac850b80549fed038175a6ce33673b3389595178d5c3a31936?s=96&r=g\",\"caption\":\"mounika\"},\"url\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/author\\\/mounika\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Pheonix Solutions - We Empower Your Business Growth","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/pheonixsolutions.com\/blog\/1-apis\/","og_locale":"en_US","og_type":"article","og_title":"Pheonix Solutions - We Empower Your Business Growth","og_description":"API Stands for Application Programming Interface. APIs have a set of rules that allow different software applications to communicate with each other, generally letting them exchange data and perform operations simultaneously.APIs are important because they allow different software systems to work together, combining their functionalities. They help developers to create&hellip; Continue Reading 1. APIs","og_url":"https:\/\/pheonixsolutions.com\/blog\/1-apis\/","og_site_name":"PHEONIXSOLUTIONS","article_publisher":"https:\/\/www.facebook.com\/PheonixSolutions-209942982759387\/","article_published_time":"2024-07-17T17:21:55+00:00","article_modified_time":"2024-07-24T20:36:37+00:00","og_image":[{"width":3837,"height":2540,"url":"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2016\/09\/PX2.png","type":"image\/png"}],"author":"mounika","twitter_card":"summary_large_image","twitter_creator":"@pheonixsolution","twitter_site":"@pheonixsolution","twitter_misc":{"Written by":"mounika","Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/pheonixsolutions.com\/blog\/1-apis\/#article","isPartOf":{"@id":"https:\/\/pheonixsolutions.com\/blog\/1-apis\/"},"author":{"name":"mounika","@id":"https:\/\/pheonixsolutions.com\/blog\/#\/schema\/person\/01d9ea3b8083c6d2fbabebbbb9f6ec9b"},"headline":"1. APIs","datePublished":"2024-07-17T17:21:55+00:00","dateModified":"2024-07-24T20:36:37+00:00","mainEntityOfPage":{"@id":"https:\/\/pheonixsolutions.com\/blog\/1-apis\/"},"wordCount":358,"commentCount":0,"publisher":{"@id":"https:\/\/pheonixsolutions.com\/blog\/#organization"},"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/pheonixsolutions.com\/blog\/1-apis\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/pheonixsolutions.com\/blog\/1-apis\/","url":"https:\/\/pheonixsolutions.com\/blog\/1-apis\/","name":"Pheonix Solutions - We Empower Your Business Growth","isPartOf":{"@id":"https:\/\/pheonixsolutions.com\/blog\/#website"},"datePublished":"2024-07-17T17:21:55+00:00","dateModified":"2024-07-24T20:36:37+00:00","breadcrumb":{"@id":"https:\/\/pheonixsolutions.com\/blog\/1-apis\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/pheonixsolutions.com\/blog\/1-apis\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/pheonixsolutions.com\/blog\/1-apis\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/pheonixsolutions.com\/blog\/"},{"@type":"ListItem","position":2,"name":"1. APIs"}]},{"@type":"WebSite","@id":"https:\/\/pheonixsolutions.com\/blog\/#website","url":"https:\/\/pheonixsolutions.com\/blog\/","name":"Pheonix Solutions","description":"We Empower Your Business Growth","publisher":{"@id":"https:\/\/pheonixsolutions.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/pheonixsolutions.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/pheonixsolutions.com\/blog\/#organization","name":"PheonixSolutions","url":"https:\/\/pheonixsolutions.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/pheonixsolutions.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2016\/12\/logo.png","contentUrl":"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2016\/12\/logo.png","width":454,"height":300,"caption":"PheonixSolutions"},"image":{"@id":"https:\/\/pheonixsolutions.com\/blog\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/PheonixSolutions-209942982759387\/","https:\/\/x.com\/pheonixsolution"]},{"@type":"Person","@id":"https:\/\/pheonixsolutions.com\/blog\/#\/schema\/person\/01d9ea3b8083c6d2fbabebbbb9f6ec9b","name":"mounika","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/649da26ffd31b2ac850b80549fed038175a6ce33673b3389595178d5c3a31936?s=96&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/649da26ffd31b2ac850b80549fed038175a6ce33673b3389595178d5c3a31936?s=96&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/649da26ffd31b2ac850b80549fed038175a6ce33673b3389595178d5c3a31936?s=96&r=g","caption":"mounika"},"url":"https:\/\/pheonixsolutions.com\/blog\/author\/mounika\/"}]}},"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/p7F4uM-26e","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/8074","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/users\/501"}],"replies":[{"embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/comments?post=8074"}],"version-history":[{"count":0,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/8074\/revisions"}],"wp:attachment":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/media?parent=8074"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/categories?post=8074"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/tags?post=8074"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}