{"id":5478,"date":"2012-05-11T10:31:34","date_gmt":"2012-05-11T05:01:34","guid":{"rendered":"http:\/\/www.tothenew.com\/blog\/?p=5478"},"modified":"2012-05-11T10:31:34","modified_gmt":"2012-05-11T05:01:34","slug":"change-user-preferred-locale-using-springs-sessionlocaleresolver","status":"publish","type":"post","link":"https:\/\/www.tothenew.com\/blog\/change-user-preferred-locale-using-springs-sessionlocaleresolver\/","title":{"rendered":"Change user preferred locale using spring&#8217;s SessionLocaleResolver"},"content":{"rendered":"<p>Here we are going to talk about a scenario where there are some records in database which are specific to locale and they need to be displayed as per user&#8217;s current locale at number of places.Also user can change its preferred locale.<\/p>\n<p>For this I preferred to set the user&#8217;s locale in the session object. There are two ways to do this :-<\/p>\n<p>1. Add attribute &#8220;lang&#8221; to the request and it will be available to session automatically.<\/p>\n<p>For example: whenever user clicks on the link, the language will change to English and the user will remain on the same page.<strong><br \/>\n<\/strong><\/p>\n<p>[groovy]<\/p>\n<p>&lt;g:link controller=&quot;${params.controller}&quot; action=&quot;${params.action}&quot; params=&quot;${params+[lang:&#8217;en&#8217;]}&quot;&gt;English&lt;\/g:link&gt;<br \/>\n\/*Add different languages here*\/<br \/>\n[\/groovy]<\/p>\n<p>2.Also set default locale in the session in case, it is not set.<\/p>\n<p>For that add following to any Filters :-<\/p>\n<p>[groovy]<\/p>\n<p>if (!session.&#8217;org.springframework.web.servlet.i18n.SessionLocaleResolver.LOCALE&#8217;) {<br \/>\nLocaleResolver localeResolver = RequestContextUtils.getLocaleResolver(request);<br \/>\nlocaleResolver.setLocale(request, response, new Locale(&#8216;en&#8217;));<\/p>\n<p>}<\/p>\n<p>[\/groovy]<\/p>\n<p>This sets the locale in spring&#8217;s SessionLocaleResolver class. Session always refer for the locale from here only.<\/p>\n<p>Now one can check the locale wherever session is available. For example in GSPs:<\/p>\n<p>[groovy]<\/p>\n<p>&lt;g:if test=&quot;${session.&#8217;org.springframework.web.servlet.i18n.SessionLocaleResolver.LOCALE&#8217;.toString()==&#8217;en&#8217;}&quot;&gt;<\/p>\n<p>[\/groovy]<\/p>\n<p><strong>Note<\/strong>: This implementation is useful to set locale in session (for accessing many times). Otherwise locale is available directly from current request as given below:-<\/p>\n<p>[groovy]<br \/>\nimport org.springframework.web.servlet.support.RequestContextUtils as RCU<br \/>\nLocale locale=RCU.getLocale(request)<br \/>\n[\/groovy]<\/p>\n<p>Hope this helped!<br \/>\nNitesh Goel<br \/>\n[Intelligrape Software Pvt. Ltd.]<\/p>\n<div style=\"width: 1px;height: 1px;overflow: hidden\">RequestContextUtils<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Here we are going to talk about a scenario where there are some records in database which are specific to locale and they need to be displayed as per user&#8217;s current locale at number of places.Also user can change its preferred locale. For this I preferred to set the user&#8217;s locale in the session object. [&hellip;]<\/p>\n","protected":false},"author":42,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"iawp_total_views":23,"footnotes":""},"categories":[7],"tags":[4840,32,108,816,312,818,315,4841],"class_list":["post-5478","post","type-post","status-publish","format-standard","hentry","category-grails","tag-grails","tag-gsp","tag-session","tag-lang","tag-locale","tag-requestcontextutils","tag-sessionlocaleresolver","tag-spring"],"aioseo_notices":[],"aioseo_head":"\n\t\t<!-- All in One SEO 5.0.0.1 - aioseo.com -->\n\t<meta name=\"description\" content=\"Here we are going to talk about a scenario where there are some records in database which are specific to locale and they need to be displayed as per user&#039;s current locale at number of places.Also user can change its preferred locale. For this I preferred to set the user&#039;s locale in the session object.\" \/>\n\t<meta name=\"robots\" content=\"max-image-preview:large\" \/>\n\t<meta name=\"author\" content=\"Nitesh\"\/>\n\t<link rel=\"canonical\" href=\"https:\/\/www.tothenew.com\/blog\/change-user-preferred-locale-using-springs-sessionlocaleresolver\/\" \/>\n\t<meta name=\"generator\" content=\"All in One SEO (AIOSEO) 5.0.0.1\" \/>\n\t\t<meta property=\"og:locale\" content=\"en_US\" \/>\n\t\t<meta property=\"og:site_name\" content=\"TO THE NEW BLOG\" \/>\n\t\t<meta property=\"og:type\" content=\"blog\" \/>\n\t\t<meta property=\"og:title\" content=\"Change user preferred locale using spring\u2019s SessionLocaleResolver | TO THE NEW Blog\" \/>\n\t\t<meta property=\"og:description\" content=\"Here we are going to talk about a scenario where there are some records in database which are specific to locale and they need to be displayed as per user&#039;s current locale at number of places.Also user can change its preferred locale. For this I preferred to set the user&#039;s locale in the session object.\" \/>\n\t\t<meta property=\"og:url\" content=\"https:\/\/www.tothenew.com\/blog\/change-user-preferred-locale-using-springs-sessionlocaleresolver\/\" \/>\n\t\t<meta property=\"og:image\" content=\"https:\/\/www.tothenew.com\/blog\/wp-content\/themes\/ttn\/images\/social-logo.png\" \/>\n\t\t<meta property=\"og:image:secure_url\" content=\"https:\/\/www.tothenew.com\/blog\/wp-content\/themes\/ttn\/images\/social-logo.png\" \/>\n\t\t<meta name=\"twitter:card\" content=\"summary\" \/>\n\t\t<meta name=\"twitter:site\" content=\"@tothenew\" \/>\n\t\t<meta name=\"twitter:title\" content=\"Change user preferred locale using spring\u2019s SessionLocaleResolver | TO THE NEW Blog\" \/>\n\t\t<meta name=\"twitter:description\" content=\"Here we are going to talk about a scenario where there are some records in database which are specific to locale and they need to be displayed as per user&#039;s current locale at number of places.Also user can change its preferred locale. For this I preferred to set the user&#039;s locale in the session object.\" \/>\n\t\t<meta name=\"twitter:image\" content=\"https:\/\/www.tothenew.com\/blog\/wp-content\/themes\/ttn\/images\/social-logo.png\" \/>\n\t\t<script type=\"application\/ld+json\" class=\"aioseo-schema\">\n\t\t\t{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/change-user-preferred-locale-using-springs-sessionlocaleresolver\\\/#article\",\"name\":\"Change user preferred locale using spring\\u2019s SessionLocaleResolver | TO THE NEW Blog\",\"headline\":\"Change user preferred locale using spring&#8217;s SessionLocaleResolver\",\"author\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/author\\\/nitesh\\\/#author\"},\"publisher\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/#organization\"},\"datePublished\":\"2012-05-11T10:31:34+05:30\",\"dateModified\":\"2012-05-11T10:31:34+05:30\",\"inLanguage\":\"en-US\",\"commentCount\":5,\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/change-user-preferred-locale-using-springs-sessionlocaleresolver\\\/#webpage\"},\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/change-user-preferred-locale-using-springs-sessionlocaleresolver\\\/#webpage\"},\"articleSection\":\"Grails, Grails, gsp, HTTP session, lang, locale, RequestContextUtils, SessionLocaleResolver, Spring\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/change-user-preferred-locale-using-springs-sessionlocaleresolver\\\/#breadcrumblist\",\"itemListElement\":[{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog#listItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.tothenew.com\\\/blog\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/category\\\/grails\\\/#listItem\",\"name\":\"Grails\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/category\\\/grails\\\/#listItem\",\"position\":2,\"name\":\"Grails\",\"item\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/category\\\/grails\\\/\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/change-user-preferred-locale-using-springs-sessionlocaleresolver\\\/#listItem\",\"name\":\"Change user preferred locale using spring&#8217;s SessionLocaleResolver\"},\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog#listItem\",\"name\":\"Home\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/change-user-preferred-locale-using-springs-sessionlocaleresolver\\\/#listItem\",\"position\":3,\"name\":\"Change user preferred locale using spring&#8217;s SessionLocaleResolver\",\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/category\\\/grails\\\/#listItem\",\"name\":\"Grails\"}}]},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/#organization\",\"name\":\"TO THE NEW Blog\",\"url\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/author\\\/nitesh\\\/#author\",\"url\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/author\\\/nitesh\\\/\",\"name\":\"Nitesh\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/change-user-preferred-locale-using-springs-sessionlocaleresolver\\\/#authorImage\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/7a643fc83e3333024306c9625557c6bfea7cf3bd570a7adcebe2bd44b91b663c?s=96&d=mm&r=g\",\"width\":96,\"height\":96,\"caption\":\"Nitesh\"}},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/change-user-preferred-locale-using-springs-sessionlocaleresolver\\\/#webpage\",\"url\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/change-user-preferred-locale-using-springs-sessionlocaleresolver\\\/\",\"name\":\"Change user preferred locale using spring\\u2019s SessionLocaleResolver | TO THE NEW Blog\",\"description\":\"Here we are going to talk about a scenario where there are some records in database which are specific to locale and they need to be displayed as per user's current locale at number of places.Also user can change its preferred locale. For this I preferred to set the user's locale in the session object.\",\"inLanguage\":\"en-US\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/#website\"},\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/change-user-preferred-locale-using-springs-sessionlocaleresolver\\\/#breadcrumblist\"},\"author\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/author\\\/nitesh\\\/#author\"},\"creator\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/author\\\/nitesh\\\/#author\"},\"datePublished\":\"2012-05-11T10:31:34+05:30\",\"dateModified\":\"2012-05-11T10:31:34+05:30\"},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/\",\"name\":\"TO THE NEW Blog\",\"inLanguage\":\"en-US\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.tothenew.com\\\/blog\\\/#organization\"}}]}\n\t\t<\/script>\n\t\t<!-- All in One SEO -->\n\n","aioseo_head_json":{"title":"Change user preferred locale using spring\u2019s SessionLocaleResolver | TO THE NEW Blog","description":"Here we are going to talk about a scenario where there are some records in database which are specific to locale and they need to be displayed as per user's current locale at number of places.Also user can change its preferred locale. For this I preferred to set the user's locale in the session object.","canonical_url":"https:\/\/www.tothenew.com\/blog\/change-user-preferred-locale-using-springs-sessionlocaleresolver\/","robots":"max-image-preview:large","keywords":"","webmasterTools":{"miscellaneous":""},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.tothenew.com\/blog\/change-user-preferred-locale-using-springs-sessionlocaleresolver\/#article","name":"Change user preferred locale using spring\u2019s SessionLocaleResolver | TO THE NEW Blog","headline":"Change user preferred locale using spring&#8217;s SessionLocaleResolver","author":{"@id":"https:\/\/www.tothenew.com\/blog\/author\/nitesh\/#author"},"publisher":{"@id":"https:\/\/www.tothenew.com\/blog\/#organization"},"datePublished":"2012-05-11T10:31:34+05:30","dateModified":"2012-05-11T10:31:34+05:30","inLanguage":"en-US","commentCount":5,"mainEntityOfPage":{"@id":"https:\/\/www.tothenew.com\/blog\/change-user-preferred-locale-using-springs-sessionlocaleresolver\/#webpage"},"isPartOf":{"@id":"https:\/\/www.tothenew.com\/blog\/change-user-preferred-locale-using-springs-sessionlocaleresolver\/#webpage"},"articleSection":"Grails, Grails, gsp, HTTP session, lang, locale, RequestContextUtils, SessionLocaleResolver, Spring"},{"@type":"BreadcrumbList","@id":"https:\/\/www.tothenew.com\/blog\/change-user-preferred-locale-using-springs-sessionlocaleresolver\/#breadcrumblist","itemListElement":[{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog#listItem","position":1,"name":"Home","item":"https:\/\/www.tothenew.com\/blog","nextItem":{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog\/category\/grails\/#listItem","name":"Grails"}},{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog\/category\/grails\/#listItem","position":2,"name":"Grails","item":"https:\/\/www.tothenew.com\/blog\/category\/grails\/","nextItem":{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog\/change-user-preferred-locale-using-springs-sessionlocaleresolver\/#listItem","name":"Change user preferred locale using spring&#8217;s SessionLocaleResolver"},"previousItem":{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog#listItem","name":"Home"}},{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog\/change-user-preferred-locale-using-springs-sessionlocaleresolver\/#listItem","position":3,"name":"Change user preferred locale using spring&#8217;s SessionLocaleResolver","previousItem":{"@type":"ListItem","@id":"https:\/\/www.tothenew.com\/blog\/category\/grails\/#listItem","name":"Grails"}}]},{"@type":"Organization","@id":"https:\/\/www.tothenew.com\/blog\/#organization","name":"TO THE NEW Blog","url":"https:\/\/www.tothenew.com\/blog\/"},{"@type":"Person","@id":"https:\/\/www.tothenew.com\/blog\/author\/nitesh\/#author","url":"https:\/\/www.tothenew.com\/blog\/author\/nitesh\/","name":"Nitesh","image":{"@type":"ImageObject","@id":"https:\/\/www.tothenew.com\/blog\/change-user-preferred-locale-using-springs-sessionlocaleresolver\/#authorImage","url":"https:\/\/secure.gravatar.com\/avatar\/7a643fc83e3333024306c9625557c6bfea7cf3bd570a7adcebe2bd44b91b663c?s=96&d=mm&r=g","width":96,"height":96,"caption":"Nitesh"}},{"@type":"WebPage","@id":"https:\/\/www.tothenew.com\/blog\/change-user-preferred-locale-using-springs-sessionlocaleresolver\/#webpage","url":"https:\/\/www.tothenew.com\/blog\/change-user-preferred-locale-using-springs-sessionlocaleresolver\/","name":"Change user preferred locale using spring\u2019s SessionLocaleResolver | TO THE NEW Blog","description":"Here we are going to talk about a scenario where there are some records in database which are specific to locale and they need to be displayed as per user's current locale at number of places.Also user can change its preferred locale. For this I preferred to set the user's locale in the session object.","inLanguage":"en-US","isPartOf":{"@id":"https:\/\/www.tothenew.com\/blog\/#website"},"breadcrumb":{"@id":"https:\/\/www.tothenew.com\/blog\/change-user-preferred-locale-using-springs-sessionlocaleresolver\/#breadcrumblist"},"author":{"@id":"https:\/\/www.tothenew.com\/blog\/author\/nitesh\/#author"},"creator":{"@id":"https:\/\/www.tothenew.com\/blog\/author\/nitesh\/#author"},"datePublished":"2012-05-11T10:31:34+05:30","dateModified":"2012-05-11T10:31:34+05:30"},{"@type":"WebSite","@id":"https:\/\/www.tothenew.com\/blog\/#website","url":"https:\/\/www.tothenew.com\/blog\/","name":"TO THE NEW Blog","inLanguage":"en-US","publisher":{"@id":"https:\/\/www.tothenew.com\/blog\/#organization"}}]},"og:locale":"en_US","og:site_name":"TO THE NEW BLOG","og:type":"blog","og:title":"Change user preferred locale using spring\u2019s SessionLocaleResolver | TO THE NEW Blog","og:description":"Here we are going to talk about a scenario where there are some records in database which are specific to locale and they need to be displayed as per user's current locale at number of places.Also user can change its preferred locale. For this I preferred to set the user's locale in the session object.","og:url":"https:\/\/www.tothenew.com\/blog\/change-user-preferred-locale-using-springs-sessionlocaleresolver\/","og:image":"https:\/\/www.tothenew.com\/blog\/wp-content\/themes\/ttn\/images\/social-logo.png","og:image:secure_url":"https:\/\/www.tothenew.com\/blog\/wp-content\/themes\/ttn\/images\/social-logo.png","twitter:card":"summary","twitter:site":"@tothenew","twitter:title":"Change user preferred locale using spring\u2019s SessionLocaleResolver | TO THE NEW Blog","twitter:description":"Here we are going to talk about a scenario where there are some records in database which are specific to locale and they need to be displayed as per user's current locale at number of places.Also user can change its preferred locale. For this I preferred to set the user's locale in the session object.","twitter:image":"https:\/\/www.tothenew.com\/blog\/wp-content\/themes\/ttn\/images\/social-logo.png"},"aioseo_meta_data":{"post_id":"5478","title":null,"description":null,"keywords":null,"keyphrases":null,"primary_term":null,"canonical_url":null,"og_title":null,"og_description":null,"og_object_type":"default","og_image_type":"default","og_image_url":null,"og_image_width":null,"og_image_height":null,"og_image_custom_url":null,"og_image_custom_fields":null,"og_video":null,"og_custom_url":null,"og_article_section":null,"og_article_tags":null,"twitter_use_og":false,"twitter_card":"default","twitter_image_type":"default","twitter_image_url":null,"twitter_image_custom_url":null,"twitter_image_custom_fields":null,"twitter_title":null,"twitter_description":null,"schema":{"blockGraphs":[],"customGraphs":[],"default":{"data":{"Article":[],"Course":[],"Dataset":[],"FAQPage":[],"Movie":[],"Person":[],"Product":[],"ProductReview":[],"Car":[],"Recipe":[],"Service":[],"SoftwareApplication":[],"WebPage":[]},"graphName":"Article","isEnabled":true},"graphs":[]},"schema_type":null,"schema_type_options":null,"pillar_content":false,"robots_default":true,"robots_noindex":false,"robots_noarchive":false,"robots_nosnippet":false,"robots_nofollow":false,"robots_noimageindex":false,"robots_noodp":false,"robots_notranslate":false,"robots_max_snippet":null,"robots_max_videopreview":null,"robots_max_imagepreview":"large","priority":null,"frequency":null,"local_seo":null,"limit_modified_date":false,"created":"2021-04-29 18:03:25","updated":"2024-02-29 09:29:24","focus_keyword":null,"additional_keywords":null,"truseo_locale":null,"ai":null,"breadcrumb_settings":null,"seo_analyzer_scan_date":null},"aioseo_breadcrumb":"<div class=\"aioseo-breadcrumbs\"><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/www.tothenew.com\/blog\" title=\"Home\">Home<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/www.tothenew.com\/blog\/category\/grails\/\" title=\"Grails\">Grails<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\tChange user preferred locale using spring\u2019s SessionLocaleResolver\n\t\t<\/span><\/div>","aioseo_breadcrumb_json":[{"label":"Home","link":"https:\/\/www.tothenew.com\/blog"},{"label":"Grails","link":"https:\/\/www.tothenew.com\/blog\/category\/grails\/"},{"label":"Change user preferred locale using spring&#8217;s SessionLocaleResolver","link":"https:\/\/www.tothenew.com\/blog\/change-user-preferred-locale-using-springs-sessionlocaleresolver\/"}],"_links":{"self":[{"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/posts\/5478","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/users\/42"}],"replies":[{"embeddable":true,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/comments?post=5478"}],"version-history":[{"count":0,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/posts\/5478\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/media?parent=5478"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/categories?post=5478"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/tags?post=5478"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}