{"id":3247,"date":"2020-05-19T18:44:21","date_gmt":"2020-05-19T13:14:21","guid":{"rendered":"https:\/\/www.h2kinfosys.com\/blog\/?p=3247"},"modified":"2024-10-10T13:37:32","modified_gmt":"2024-10-10T08:07:32","slug":"selenium-webdriver-xpath-complete-tutorial","status":"publish","type":"post","link":"https:\/\/www.h2kinfosys.com\/blog\/selenium-webdriver-xpath-complete-tutorial\/","title":{"rendered":"Selenium WebDriver XPath: Complete Tutorial"},"content":{"rendered":"\n<p>In this article, we study Selenium WebDriver XPath and learn how to handle various XPath expressions to locate complex or dynamic elements, whose attributes change dynamically whenever the developer makes changes in the code.<\/p>\n\n\n\n<p>In <a href=\"https:\/\/www.h2kinfosys.com\/courses\/selenium-webdriver-junit-training-course\">Selenium<\/a>, if elements are not found with general locators like id, name, class, linkText, partialLinkText then XPath is used to find an element on the webpage.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>What is XPath?<\/strong><\/h2>\n\n\n\n<p>XPath is called as XML Path. It is a query language or syntax used for navigating to any element on the web page through XML documents. It is one of the important strategies to locate elements in selenium. XPath expressions is used to locate any element on a webpage using HTML DOM structure.<\/p>\n\n\n\n<p>The basic syntax of XPath is explained with below screenshot.<\/p>\n\n\n\n<p><strong><img fetchpriority=\"high\" decoding=\"async\" width=\"602\" height=\"336\" alt=\"Xpath.PNG\" src=\"https:\/\/lh3.googleusercontent.com\/sDUD5OjsIiinnf9E9EDMZZhnTIxy6aCbUu9Xzb4yDIQFq5QRnT0g3Z_xuaVlWr0cK5n7JrutV_tnhKVFcVHGPI5V-A5WRgEdIEQflDrWwX_eVU1FBF6WsBX4O200kKH1JMkn2pKzD0i29aNv-Q\" title=\"\"><\/strong><\/p>\n\n\n\n<p><strong>Syntax for XPath<\/strong><\/p>\n\n\n\n<p>The standard syntax of an <a href=\"https:\/\/en.wikipedia.org\/wiki\/XPath\" rel=\"nofollow noopener\" target=\"_blank\">Selenium XPath<\/a> is<\/p>\n\n\n\n<p>[box type=&#8221;shadow&#8221; align=&#8221;&#8221; class=&#8221;&#8221; width=&#8221;&#8221;]\/\/tag[@atrributeName=&#8217;attributeValues&#8217;][\/box]<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>\/\/: <\/strong>It is used to choose the current node<\/li>\n\n\n\n<li><strong>tagname: <\/strong>It is the tagname of the particular node<\/li>\n\n\n\n<li><strong>@: <\/strong>It is used for selection of an attribute<\/li>\n\n\n\n<li><strong>Attribute: <\/strong>It is the attribute name of a node<\/li>\n\n\n\n<li><strong>Value: <\/strong>It defines the attribute value<\/li>\n<\/ul>\n\n\n\n<p>There are different locators to <a href=\"https:\/\/www.h2kinfosys.com\/blog\/find-element-findelements-selenium-webdriver\/\">find the element on the web pages<\/a><\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><tbody><tr><td>Locators<\/td><td>Description<\/td><\/tr><tr><td>Id<\/td><td>Finds the element by ID of the element on a webpage<\/td><\/tr><tr><td>Classname<\/td><td>Finds the element by Classname of the element on a webpage<\/td><\/tr><tr><td>Name<\/td><td>Finds the element by name of the element on a webpage<\/td><\/tr><tr><td>LinkText<\/td><td>Finds the element by link text of the element on a webpage<\/td><\/tr><tr><td>XPath<\/td><td>XPath used for finding dynamic elements on a webpage and traverse among various elements&nbsp;<\/td><\/tr><tr><td>CSSSelector<\/td><td>It locates elements on a webpage which have no id, name or class<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Types of XPath<\/strong><\/h2>\n\n\n\n<p>There are two types of XPath expressions<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li><strong>Absolute XPath<\/strong><\/li>\n\n\n\n<li><strong>Relative XPath<\/strong><\/li>\n<\/ol>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Absolute XPath<\/strong><\/h3>\n\n\n\n<p>It is the direct way to find the element on the webpage. Absolute XPath uses full path starting from root element to the desired UI element. The main disadvantage of Absolute XPath is that if developer makes any changes in the path of the element then our written XPath gets failed. The main advantage with absolute XPath is that it identifies the element very fast.<\/p>\n\n\n\n<p>The characteristic of XPath expression is that it begins with the single forward slash(\/), which means that it starts the selection from the root node.<\/p>\n\n\n\n<p>The example of an absolute XPath of an element is shown below<\/p>\n\n\n\n<p>[box type=&#8221;shadow&#8221; align=&#8221;center&#8221; class=&#8221;&#8221; width=&#8221;&#8221;]\/html\/head\/body\/table\/tbody\/tr\/th[\/box]<\/p>\n\n\n\n<p>If the developer adds a tag between the body and table.<\/p>\n\n\n\n<p>[box type=&#8221;shadow&#8221; align=&#8221;center&#8221; class=&#8221;&#8221; width=&#8221;&#8221;]\/html\/head\/body\/form\/table\/tbody\/tr\/th[\/box]<\/p>\n\n\n\n<p>The first path will not work as \u201cform\u201d tag is added between body and a table<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Relative XPath<\/strong><\/h3>\n\n\n\n<p>A relative XPath begin by referencing from the middle of the HTML DOM structure. It starts with the double forward-slash(\/\/). It doesn\u2019t need to start from the root node, which means it starts searching for the element anywhere at the webpage.<\/p>\n\n\n\n<p>&nbsp;The example of an relative XPath of an element is shown below<\/p>\n\n\n\n<p>[box type=&#8221;shadow&#8221; align=&#8221;center&#8221; class=&#8221;&#8221; width=&#8221;&#8221;]\/\/input[@id=&#8217;email&#8217;][\/box]<\/p>\n\n\n\n<p>Now, let\u2019s consider an example<\/p>\n\n\n\n<p>Let\u2019s launch Google chrome and navigate to google.com<\/p>\n\n\n\n<p>Here, by using an XPath we will try to locate the search bar. On inspecting the search bar web element you can see it having an input tag and attributes like class and id. Now, by using the tag name and attributes you can generate the XPath which will locate the search bar.<\/p>\n\n\n\n<p><img decoding=\"async\" width=\"602\" height=\"88\" alt=\"search.PNG\" src=\"https:\/\/lh4.googleusercontent.com\/3CHzPIGjd2UHDpeC6ri8u2begEPFG4MCCRuUphP6a0aXYyDL1WKhAvEUtIz0KKo3Qwz4PgSg8DGZfbSmGeV4tqz6xw4ptyWC-qf4UOskrIcPCsAV417eWTWlkwR1Ue0YbCd3DU3ZZDqIDmZpdA\" title=\"\"><\/p>\n\n\n\n<p>Here, press Ctrl + F and click Elements tab to open a search box in developer\u2019s chrome tool. Based on this criteria you can write XPath to search for the web element. From the above image, you can see it has an input tag and you can start writing with \/\/input which implies tag name. Now, we use the attribute<\/p>\n\n\n\n<p>name and pass the name attribute \u2018q\u2019 as its value in single quotes. This shows XPath as below:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/logos-world.net\/wp-content\/uploads\/2020\/05\/Facebook-Logo.jpg\" alt=\"\" title=\"\"><\/figure>\n\n\n\n<p><img decoding=\"async\" width=\"602\" height=\"181\" alt=\"input1.PNG\" src=\"https:\/\/lh3.googleusercontent.com\/N7k2jcSr5cls-MjC-vA9SLTvBn0vyjoVjP6E0iijZdRpdNbLW0sXZqsnNnG4fSc9D4PGt1cRp4xTtR2JcokLPdq7y8Ijp4YWa5uguPMs1jwGxII0NFN-90LqrSaGZROxzBkmbsyG0-od57neEg\" title=\"\"><\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>How to generate XPath<\/strong><\/h2>\n\n\n\n<p>From the above image you can see that the element got highlighted on writing on XPath which shows that particular element was located using XPath.<\/p>\n\n\n\n<p>Generally, we generate the XPath in two different ways i.e manually and by inbuilt utilities. But sometimes the HTML file is quite large or complex and writing the XPath manually each time would be a quite difficult task. In such cases, there are certain inbuilt utilities which can help us.<\/p>\n\n\n\n<p>Chrome Browser has Inbuilt utility to inspect and generate the XPath.<\/p>\n\n\n\n<p><strong>Example:<\/strong><\/p>\n\n\n\n<p>In below example, we login to Facebook application by entering Email, Password and by clicking Log In button by opening Chrome browser.<\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" width=\"602\" height=\"309\" alt=\"facebook.PNG\" src=\"https:\/\/lh5.googleusercontent.com\/Fc7Ri-JQvsqrD5InuP5m1rfjWps8zRujCNFgIQISXKGZWuoq8xEcTrVbIvCbsKoAEUdKNhc3TZB0FqCyarnZ117Y1SZQ8yZJgwk3XXi24BlV8ByZAQyxwCSPVjiT-ShR47kD_emeOx5gGUEULA\" title=\"\"><\/p>\n\n\n\n<p>Right-click on Email or Phone, and select Inspect to inspect the Email or phone web element.<\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" width=\"458\" height=\"482\" alt=\"Email.PNG\" src=\"https:\/\/lh3.googleusercontent.com\/JCxd2NEBs74Diq2yDjCf8bK2upJTaQ2PeiU3H4Oy-OBAh708uQJELyzvYbMi2PxREU2oXpIJtY1lBrNfZphUezQAXuq2VUEYRaqZTX6gkIMlnCCuXSYhsj0yp3LS_gJzX2ira_zfDjRioWnu_w\" title=\"\"><\/p>\n\n\n\n<p>It will open HTML DOM structure once inspecting the Email or Phone.<\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" width=\"602\" height=\"156\" alt=\"inspect.PNG\" src=\"https:\/\/lh6.googleusercontent.com\/N5MMATak4B2iVDr9XNTiKTkYJTCHAv6vryvYpVz0jUoCNjCj8HFLYTFkV1wrsV0f7SJgAnoX9-iLYhnoapEKZyzvueOWkPVhdsEE_5m_pV6uBVoAKRkoKDCMar6II-UhqO0J4Ym2wSpkSpkYUg\" title=\"\"><\/p>\n\n\n\n<p>Right click on HTML DOM structure &gt; Select Copy and Click on Copy XPath to get the XPath of Email or Phone<\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" width=\"602\" height=\"264\" alt=\"xpath1.PNG\" src=\"https:\/\/lh5.googleusercontent.com\/TbqGPQ5lj5lL5cmFHZHUYHP-4fLjbgxOeRw9SntKW-3uYNl94WTYMpFD6jcegE2YvH_rzDolBn5tU9Sx0tvcK9KvQWICjI67w0NFRr55nYK_4IJjhiyjNvGtEAQnBldSog5vVY2GTJBrSxV7uQ\" title=\"\"><\/p>\n\n\n\n<p>In the above case, the XPath is<\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" width=\"602\" height=\"156\" alt=\"email1.png\" src=\"https:\/\/lh6.googleusercontent.com\/OQjnAvluMJ4RtOvUrfxb2hRAKHSbg63wRk4uZPLYB193PrkesGi7P-NW0s99TZcYKSHYXN6v1XvdTLyGULCzVd3MWr4TP6_X5tLSzBpsgkE2n29dDWw5K1_6ooaMxO57SuYR1Klx_dVBaJ28vA\" title=\"\"><\/p>\n\n\n\n<p>Right-click on Password field and select Inspect to inspect the Password web element.<\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" width=\"602\" height=\"196\" alt=\"password.PNG\" src=\"https:\/\/lh5.googleusercontent.com\/iLDnBhB45gILn7HYVlC3CnWSg8MhZEF2-dbG7xTfPJ7J1TP8cfC8HyGCCx7lGjuhYKgLoRMcZ_BsmP_GwAeRlkWYcMSEJnBxsfh0QjCSR8OaBzf7ITub_c8W5RXNu6lH7gvbTAaoj8FKM3E-Ng\" title=\"\"><\/p>\n\n\n\n<p>It will open HTML DOM structure once inspecting the Password field.<\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" width=\"602\" height=\"146\" alt=\"passinspect.PNG\" src=\"https:\/\/lh5.googleusercontent.com\/sIxMjFgdKk4Uy4Lo2k9LXx6j3mmoThJmexcK1HF9D5gdgBlXMpflfmT5RKiFqOybWgpEz4T67Gkw14bfJbcP1cnH1QhT1NCV99Yerf4X5K4TNhiw0ItbG0ar1a49eli3Mldy0fD3PrGYMyBxdg\" title=\"\"><\/p>\n\n\n\n<p>Right click on HTML DOM structure &gt; Select Copy and Click on Copy XPath to get the XPath of Password field.<\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" width=\"602\" height=\"244\" alt=\"passwordxpath.PNG\" src=\"https:\/\/lh6.googleusercontent.com\/XpCcST9qtg-0-lUnx_fbJxoUY68P2pQd08eFAmbgJpdqPgKehPB90VEqjMLTKKHyJJd81Jhf2FrOELePHHMUoRO5pwHg7uFs50HFMpYlnEZjqaoWeCE0rXtbzTXvlkHIcy4IZQ4gAoUEEqZJLg\" title=\"\"><\/p>\n\n\n\n<p>In the above case, the XPath is<\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" width=\"602\" height=\"43\" alt=\"pass.PNG\" src=\"https:\/\/lh5.googleusercontent.com\/YNi1AnFAUgKcSNYIrPir82THmrjmLJEud4LgG4fBD2pCLvQlall4_KohhwbOOHJwh85Yxf0aeIiYvI4D4okRHOf-dZbTgBTbBYELiuP1RqQwYJEWf5S7JyHuM9cQHI2TiwtrHj3AX3cDypZDSA\" title=\"\"><\/p>\n\n\n\n<p>Right-click on&nbsp;<strong>Log In<\/strong>&nbsp;button and select Inspect to inspect&nbsp;<strong>Log In<\/strong>&nbsp;button<\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" width=\"602\" height=\"156\" alt=\"inspect.PNG\" src=\"https:\/\/lh6.googleusercontent.com\/N5MMATak4B2iVDr9XNTiKTkYJTCHAv6vryvYpVz0jUoCNjCj8HFLYTFkV1wrsV0f7SJgAnoX9-iLYhnoapEKZyzvueOWkPVhdsEE_5m_pV6uBVoAKRkoKDCMar6II-UhqO0J4Ym2wSpkSpkYUg\" title=\"\"><\/p>\n\n\n\n<p>It will open HTML DOM structure once inspecting the Log In button.<\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" width=\"602\" height=\"118\" alt=\"logininspect.PNG\" src=\"https:\/\/lh4.googleusercontent.com\/JbMser1RVppSL6WbGOYJMM9wJR2UxYr3TNl3s0TUSwbSxqZ8iSwrdtfjGxsx2jszvsZIKZ9cKdJDLyh_zbito9Kavvzxxvqup6df1k2BjwNnCHlhmIIUD6h6TMwEgqYRH9TUIY4aKvvUQfL_Dw\" title=\"\"><\/p>\n\n\n\n<p>Right click on HTML DOM structure &gt; Select Copy and Click on Copy XPath to get the XPath of Log In button.<\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" width=\"602\" height=\"231\" alt=\"xpathlog.PNG\" src=\"https:\/\/lh4.googleusercontent.com\/loWB2Fm9kCR1DL-X-qV0BWWUlrjd4asd4nZAD4oBNS_Zgyy4KdYTVjRbTI71PDaySImfXEkypOIhs8WXvLMaNJS_7oL9-axfA8Q1cn7ZFmUOHDFzgASCv2wGgMmfnJDY6FPAjtKtECu78544Wg\" title=\"\"><\/p>\n\n\n\n<p>In the above case, the XPath is<\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" width=\"602\" height=\"56\" alt=\"idlog.PNG\" src=\"https:\/\/lh5.googleusercontent.com\/O8jHhR8y0uT86TSmsOkCMqIhEXkpMVo3TT4GBBJV4CqZkdY2SGmttbpFpiVbFWK0mOtFT82sh5NAawbZft6bYV1Y04aID_ExjeU0k2e-DqCNuw3Yn8RNxSe4PyQeV4rwFPu9ZDphOOZq_szJVg\" title=\"\"><\/p>\n\n\n\n<p><strong>Now,&nbsp;our&nbsp;final&nbsp;test&nbsp;script&nbsp;will&nbsp;look&nbsp;something&nbsp;like:<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"><strong>import<\/strong> org.openqa.selenium.By;\n<strong>import<\/strong> org.openqa.selenium.WebDriver;\n<strong>import<\/strong> org.openqa.selenium.chrome.ChromeDriver;\n\n<strong>public<\/strong> <strong>class<\/strong> RelativeXPathTest {\n\n<strong>public<\/strong> <strong>static<\/strong> <strong>void<\/strong> main(String[] args) {\n\/\/ <strong>TODO<\/strong> Auto-generated method stub\nSystem.<em>setProperty<\/em>(\"webdriver.chrome.driver\", \"D:\\\\Drivers\\\\geckodriver.exe \");&nbsp; &nbsp; WebDriver driver= <strong>new<\/strong> ChromeDriver();\n\n&nbsp; &nbsp; driver.get(\"https:\/\/www.facebook.com\/\");\n&nbsp; &nbsp; driver.manage().window().maximize();\n&nbsp; &nbsp; \/\/XPath for Email Field\n&nbsp; &nbsp; driver.findElement(By.<em>xpath<\/em>(\"\/\/*[@id='email']\")).sendKeys(\"xxx@gmail.com\");\n&nbsp; &nbsp; \/\/XPath for Password Field\n&nbsp; &nbsp; driver.findElement(By.<em>xpath<\/em>(\"\/\/*[@id='pass']\")).sendKeys(\"xxxxxxx\");\n&nbsp; &nbsp; \/\/XPath for Log In button\n&nbsp; &nbsp; driver.findElement(By.<em>xpath<\/em>(\"\/\/*[@id=\\\"u_0_a\\\"]\")).click();\n\n  }\n\n}\n<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>XPath Functions<\/strong><\/h2>\n\n\n\n<p>Automation using Selenium has many ways to identify an element on a web page. Sometimes elements on a web page have same attributes at that time we face problem in <a href=\"https:\/\/www.h2kinfosys.com\/blog\/webelement-in-selenium\/\">identifying the element<\/a>. Some cases can be elements having the same names and attributes or more than one button with same ids and name. In such cases, it\u2019s challenging to identify a particular object and that is where XPath comes into the picture.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Different Types of XPath Functions&nbsp;<\/strong><\/h2>\n\n\n\n<p>Below are the three XPath functions which are used mostly<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>contains()<\/li>\n\n\n\n<li>text()<\/li>\n\n\n\n<li>starts-with()<\/li>\n\n\n\n<li>And\/OR<\/li>\n<\/ol>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>contains()<\/strong><\/h3>\n\n\n\n<p>Contains() function is widely used in XPath. This method is used when the value of any attribute changes dynamically. With available partial text we can locate a web element on the web page by using this method.<\/p>\n\n\n\n<p>Examples of contains() method.<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Xpath=.\/\/* [contains (@id, \u2018button\u2019)]<\/li>\n\n\n\n<li>Xpath=\/\/*[contains(@name, \u2018login\u2019)]<\/li>\n\n\n\n<li>Xpath=\/\/*[contains(text (),\u2019automationtesting\u2019)]<\/li>\n\n\n\n<li>Xpath=\/\/*[contains (@href,\u2019https:\/\/www.google.com\u2019)]<\/li>\n\n\n\n<li>Xpath=\/\/*[contains (@type, \u2018sub-type\u2019)]<\/li>\n\n\n\n<li>\/\/span[contains(text(),'( Username : Admin | Password : qwerty )&#8217;)]<\/li>\n\n\n\n<li>\/\/a[contains(text(),&#8217;message?&#8217;)]<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>text()<\/strong><\/h3>\n\n\n\n<p>This function is used to locate an element on a web page with an exact text.&nbsp;<\/p>\n\n\n\n<p>Examples of text() method.<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\/\/span[text()='( Username : Admin | Password : admin123 )&#8217;]<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Starts-with()<\/strong><\/h3>\n\n\n\n<p>This function can be used when starting partial attribute value associated with the web element.&nbsp;<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\/\/div[starts-with(@id,message)]<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>And\/OR<\/strong>&nbsp;<\/h3>\n\n\n\n<p>expression is used when want to join two conditions together, and based on whether they are true or false.<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\/\/input[@name=&#8217;txtpassword&#8217; or @id=&#8217;txtpassword&#8217;]<\/li>\n<\/ul>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>In this article, we study Selenium WebDriver XPath and learn how to handle various XPath expressions to locate complex or dynamic elements, whose attributes change dynamically whenever the developer makes changes in the code. In Selenium, if elements are not found with general locators like id, name, class, linkText, partialLinkText then XPath is used to [&hellip;]<\/p>\n","protected":false},"author":16,"featured_media":3253,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[43],"tags":[751,156,753,752,45,3,448,51,750,755,1833,749,754],"class_list":["post-3247","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-selenium-tutorials","tag-absolute","tag-automation-testing","tag-generate-xpath","tag-relative","tag-selenium","tag-selenium-skill-test","tag-selenium-webdriver","tag-software-testing","tag-types-of-xpath","tag-types-of-xpath-functions","tag-webdriver-xpath","tag-what-is-xpath","tag-xpath-functions"],"_links":{"self":[{"href":"https:\/\/www.h2kinfosys.com\/blog\/wp-json\/wp\/v2\/posts\/3247","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.h2kinfosys.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.h2kinfosys.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.h2kinfosys.com\/blog\/wp-json\/wp\/v2\/users\/16"}],"replies":[{"embeddable":true,"href":"https:\/\/www.h2kinfosys.com\/blog\/wp-json\/wp\/v2\/comments?post=3247"}],"version-history":[{"count":0,"href":"https:\/\/www.h2kinfosys.com\/blog\/wp-json\/wp\/v2\/posts\/3247\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.h2kinfosys.com\/blog\/wp-json\/wp\/v2\/media\/3253"}],"wp:attachment":[{"href":"https:\/\/www.h2kinfosys.com\/blog\/wp-json\/wp\/v2\/media?parent=3247"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.h2kinfosys.com\/blog\/wp-json\/wp\/v2\/categories?post=3247"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.h2kinfosys.com\/blog\/wp-json\/wp\/v2\/tags?post=3247"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}