{"id":117363,"date":"2020-08-31T10:41:04","date_gmt":"2020-08-31T10:41:04","guid":{"rendered":"https:\/\/blog.finxter.com\/?p=12462"},"modified":"2020-08-31T10:41:04","modified_gmt":"2020-08-31T10:41:04","slug":"python-string-formatting-how-to-become-a-string-wizard-with-the-format-specification-mini-language","status":"publish","type":"post","link":"https:\/\/sickgaming.net\/blog\/2020\/08\/31\/python-string-formatting-how-to-become-a-string-wizard-with-the-format-specification-mini-language\/","title":{"rendered":"Python String Formatting: How to Become a String Wizard with the Format Specification Mini-Language"},"content":{"rendered":"<p>Python provides fantastic string formatting options, but what if you need greater control over how values are presented? That\u2019s where format specifiers come in.&nbsp;<\/p>\n<p>This article starts with a brief <strong><em>overview of the different string formatting approaches<\/em><\/strong>. We\u2019ll then dive straight into some examples to whet your appetite for using <strong><em>Python\u2019s Format Specification Mini-Language <\/em><\/strong>in your <a href=\"https:\/\/blog.finxter.com\/how-real-freelancers-earn-money-in-2019-10-practical-python-projects\/\" target=\"_blank\" rel=\"noreferrer noopener\" title=\"How Real Freelancers Earn Money in 2020: 10 Practical Python Projects\">own projects<\/a>.<\/p>\n<p>But before all that&#8212;let&#8217;s play with string formatting yourself in the<strong> interactive Python shell<\/strong>:<\/p>\n<p> <iframe loading=\"lazy\" height=\"400px\" width=\"100%\" src=\"https:\/\/repl.it\/@finxter\/HumongousLargeServer?lite=true\" scrolling=\"no\" frameborder=\"no\" allowtransparency=\"true\" allowfullscreen=\"true\" sandbox=\"allow-forms allow-pointer-lock allow-popups allow-same-origin allow-scripts allow-modals\"><\/iframe> <\/p>\n<p><em><strong>Exercise<\/strong>: Create another variable <code>tax<\/code> and calculate the tax amount to be paid on your income (30%). Now, add both values <code>income<\/code> and <code>tax<\/code> in the string&#8212;by using the format specifier <code>%s<\/code>!<\/em><\/p>\n<p>Don&#8217;t worry if you struggle with this exercise. After reading this tutorial, you won&#8217;t! Let&#8217;s learn everything you need to know to get started with string formatting in Python.<\/p>\n<h2>String Formatting Options<\/h2>\n<p><a href=\"https:\/\/blog.finxter.com\/python-crash-course\/\" target=\"_blank\" rel=\"noreferrer noopener\" title=\"Python Programming Tutorial [+Cheat Sheets]\">Python<\/a>\u2019s string formatting tools have evolved considerably over the years.\u00a0<\/p>\n<p>The oldest approach is to use the <code>%<\/code> operator:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">>>> number = 1 + 2\n>>> 'The magic number is %s' % number 'The magic number is 3'<\/pre>\n<p><em>(The above code snippet already includes a kind of format specifier. More on that later\u2026)<\/em><\/p>\n<p>The <code>str.format()<\/code> method was then added:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">>>> 'The magic number is {}'.format(number) 'The magic number is 3'<\/pre>\n<p>Most recently, formatted string literals (otherwise known as<strong> f-strings<\/strong>) were introduced. F-strings are easier to use and lead to cleaner code, because their syntax enables the value of an expression to be placed directly inside a string:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">>>> f'The magic number is {number}' 'The magic number is 3'<\/pre>\n<p>Other options include creating template strings by importing the Template class from Python\u2019s string module, or manually formatting strings (which we\u2019ll touch on in the next section).<\/p>\n<p>If this is all fairly new to you and some more detail would be helpful before moving on, an in-depth explanation of the main string formatting approaches can be found <a href=\"https:\/\/realpython.com\/python-string-formatting\/\" target=\"_blank\" rel=\"noreferrer noopener\">here<\/a>.<\/p>\n<h2>Format Specifiers<\/h2>\n<p>With that quick summary out of the way, let\u2019s move on to the real focus of this post &#8211; explaining how format specifiers can help you control the presentation of values in strings.<\/p>\n<p><strong><em>F-strings are the clearest and fastest approach to string formatting<\/em><\/strong>, so I will be using them to illustrate the use of format specifiers throughout the rest of this article. Please bear in mind though, that specifiers can also be used with the <code>str.format()<\/code> method. Also, strings using the old <code>%<\/code> operator actually require a kind of format specification \u2013 for example, in the <code>%s<\/code> example shown in the previous section the letter <code>s<\/code> is known as a conversion type and it indicates that the standard string representation of the object should be used.\u00a0<\/p>\n<p><strong><em>So, what exactly are format specifiers and what options do they provide?<\/em><\/strong><\/p>\n<p>Simply put, format specifiers allow you to tell Python how you would like expressions embedded in strings to be displayed.<\/p>\n<h3><em>Percentage Format and Other Types<\/em><\/h3>\n<p>For example, if you want a value to be displayed as a percentage you can specify that in the following way:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">>>> asia_population = 4_647_000_000\n>>> world_population = 7_807_000_000\n>>> percent = asia_population \/ world_population\n>>> f'Proportion of global population living in Asia: {percent:.0%}' 'Proportion of global population living in Asia: 60%'<\/pre>\n<p><em>What\u2019s going on here? How has this formatting been achieved?<\/em><\/p>\n<p>Well the first thing to note is the colon <code>:<\/code> directly after the variable percent embedded in the f-string. This colon tells Python that what follows is a format specifier which should be applied to that expression\u2019s value.<\/p>\n<p>The <code>%<\/code> symbol defines that the value should be treated as a percentage, and the .0 indicates the level of precision which should be used to display it. In this case the percentage has been rounded up to a whole number, but if .1 had been specified instead the value would have been rounded to one decimal place and displayed as 59.5%; using .2 would have resulted in 59.52% and so on.<\/p>\n<p>If no format specifier had been included with the expression at all the value would have been displayed as 0.5952350454720123, which is far too precise!<\/p>\n<p>(The % symbol applied in this context should not be confused with the % operator used in old-style string formatting syntax.)<\/p>\n<p>Percentage is just the tip of the iceberg as far as type values are concerned, there are a range of other types that can be applied to integer and float values.<\/p>\n<p>For example, you can display integers in binary, octal or hex formats using the b, o and x type values respectively:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">>>> binary, octal, hexadecimal = [90, 90, 90]\n>>> f'{binary:b} - {octal:o} - {hexadecimal:x}' '1011010 - 132 - 5a'<\/pre>\n<p><strong><br \/><\/strong>For a full list of options see the link to the relevant area of the official Python documentation in the <strong><em>Further Reading<\/em><\/strong> section at the end of the article.<\/p>\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/lh5.googleusercontent.com\/fRRg7P7dvxF1BA38ATba9RQ9sNyb_yeY4ePRCmLLlFJ2O2p0EJ8X0jEppZm2ySyhXzD9lXNqA_seaApYT_C76cqXWlEi90v-oG5gY8nKlUykEFxbXjNOKl4oNPgeYabdPdhImzIe\" alt=\"A close up of a reptile Description automatically generated\"\/><\/figure>\n<h3><em>Width Format, Alignment and Fill<\/em><\/h3>\n<p>Another handy format specification feature is the ability to define the minimum width that values should take up when they\u2019re displayed in strings.<\/p>\n<p>To illustrate how this works, if you were to print the elements of the list shown below in columns without format specification, you would get the following result:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">>>> python, java, p_num, j_num = [\"Python Users\", \"Java Users\", 8.2, 7.5]\n>>> print(f\"|{python}|{java}|\\n|{p_num}|{j_num}|\")\n|Python Users|Java Users|\n|8.2|7.5|<\/pre>\n<p>Not great, but with the inclusion of some width values matters start to improve:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">>>> print(f\"|{python:16}|{java:16}|\\n|{p_num:16}|{j_num:16}|\")\n|Python Users |Java Users |\n| 8.2| 7.5|\n<\/pre>\n<p>As you can see, width is specified by adding a number after the colon.<\/p>\n<p>The new output is better, but it seems a bit strange that the titles are aligned to the left while the numbers are aligned to the right. What could be causing this?<\/p>\n<p>Well, it\u2019s actually to do with Python\u2019s default approach for different <a href=\"https:\/\/blog.finxter.com\/python-cheat-sheets\/\" target=\"_blank\" rel=\"noreferrer noopener\" title=\"Python Cheat Sheets\">data types<\/a>. String values are aligned to the left as standard, while numeric values are aligned to the right. (This might seem slightly odd, but it\u2019s consistent with the approach taken by Microsoft Excel and other spreadsheet packages.)<\/p>\n<p>Fortunately, you don\u2019t have to settle for the default settings. If you want to change this behavior you can use one of the alignment options. For example, focusing on the first column only now for the sake of simplicity, if we want to align the number to the left this can be done by adding the <code>&lt;<\/code> symbol before the <code>p_num<\/code> variable\u2019s width value:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">>>> print(f\"|{python:16}|\\n|{p_num:&lt;16}|\")\n|Python Users |\n|8.2 |<\/pre>\n<p>And the reverse can just as easily be achieved by adding a <code>><\/code> symbol in front of the width specifier associated with the title value:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">>>> print(f\"|{python:>16}|\\n|{p_num:16}|\")\n| Python Users|\n| 8.2|\n<\/pre>\n<p>But what if you want the rows to be centered? Luckily, Python\u2019s got you covered on that front too. All you need to do is use the <code>^<\/code> symbol instead:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">>>> print(f\"|{python:^16}|\\n|{p_num:^16}|\")\n| Python Users |\n| 8.2 |<\/pre>\n<p>Python\u2019s default fill character is a space, and that\u2019s what has so far been used when expanding the width of our values. We can use almost any character we like though. It just needs to be placed in front of the alignment option. For example, this is what the output looks like when an <a href=\"https:\/\/blog.finxter.com\/underscore-in-python\/\" target=\"_blank\" rel=\"noreferrer noopener\" title=\"The Single and Double Underscore in Python [\u201c_\u201d vs \u201c__\u201d]\">underscore <\/a>is used to fill the additional space in the title row of our column:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">>>> print(f\"|{python:_^16}|\\n|{p_num:^16}|\")\n|__Python Users__|\n| 8.2 |<\/pre>\n<p>It\u2019s worth noting that the same output can be achieved manually by using the <code><a href=\"https:\/\/blog.finxter.com\/python-list-to-string\/\" title=\"Python List to String: A Helpful Guide with Interactive Shell\">str()<\/a><\/code> function along with the appropriate string method (in this case <code>str.center()<\/code>):<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">>>> print(\"|\", python.center(16, \"_\"), \"|\\n|\", str(p_num).center(16), \"|\", sep=\"\")\n|__Python Users__|\n| 8.2 |<\/pre>\n<p>But the f-string approach is much more succinct and considerably <a href=\"https:\/\/blog.finxter.com\/python-profilers-how-to-speed-up-your-python-app\/\" target=\"_blank\" rel=\"noreferrer noopener\" title=\"Python cProfile \u2013 7 Strategies to Speed Up Your App\">faster <\/a>to evaluate at run time.<\/p>\n<p>Of course, outputting data formatted into rows and columns is just one example of how specifying width, alignment and fill characters can be used.<\/p>\n<p>Also, in reality if you are looking to output a table of information you aren\u2019t likely to be using a single <code><a href=\"https:\/\/blog.finxter.com\/the-separator-and-end-arguments-of-the-python-print-function\/\" title=\"Python Print Function [And Its SECRET Separator &amp; End Arguments]\">print()<\/a><\/code> statement. You will probably have several rows and columns to display, which may be constructed with a loop or comprehension, perhaps using <code><a href=\"https:\/\/blog.finxter.com\/python-join-list\/\" title=\"Python Join List [Ultimate Guide]\">str.join()<\/a><\/code> to insert separators etc.<\/p>\n<p>However, regardless of the application, in most instances using f-strings with format specifiers instead of taking a manual approach will result in more readable and efficient code.<\/p>\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/lh5.googleusercontent.com\/Y2uoC1houVz0QRgHWMOl2iWn3yq9JS4tIM8JCYRcijM3RBVz0NOymmnxkFsbPd_cVz8Uy8z2k6LA4jGrbuUgd0HLYcipt2bA-Bg7sGIRmSBYmC3lgSkSg9H1cV8chygdqkz2TKjI\" alt=\"A picture containing camera Description automatically generated\"\/><\/figure>\n<h3><em>24-Hour Clock Display<\/em><\/h3>\n<p>As another example, let\u2019s say we want to calculate what the time of day will be after a given number of hours and minutes has elapsed (starting at midnight):<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">>>> hours = 54\n>>> minutes = 128\n>>> quotient, minute = divmod(minutes, 60)\n>>> hour = (hours + quotient) % 24\n>>> f'{hour}:{minute}' '8:8'<\/pre>\n<p>So far so good. Our program is correctly telling us that after 54 hours and 128 minute the time of day will be 8 minutes past 8 in the morning, but the problem is that it\u2019s not very easy to read. Confusion could arise about whether it\u2019s actually 8 o\u2019clock in the morning or evening and having a single digit to represent the number of minutes just looks odd.<\/p>\n<p>To fix this we need to insert <a href=\"https:\/\/blog.finxter.com\/python-pad-zeros-to-a-string\/\" target=\"_blank\" rel=\"noreferrer noopener\" title=\"Python How to Pad Zeros to a String?\">leading zeros<\/a> when the hour or minute value is a single digit, which can be achieved using something called sign-aware zero padding. This sounds pretty complicated, but in essence we just need to use a 0 instead of one of the alignment values we saw earlier when defining the f-string, along with a width value of 2:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">>>> f'{hour:02}:{minute:02}' '08:08'<\/pre>\n<p>Hey presto! The time is now in a clear 24-hour clock format. This approach will work perfectly for times with double-digit hours and minutes as well, because the width value is a maximum and the zero padding will not be used if the value of either expression occupies the entire space:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">>>> hours = 47\n>>> minutes = 59\n...\n>>> f'{hour:02}:{minute:02}' '23:59'<\/pre>\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/lh5.googleusercontent.com\/YeBIxkRrF7QlqChrIjtCMREEUzQoqkApGtFTHVmyTbpJ2mD9eBiXd4Vd4mNNqrzP-0sXBr4m5_9OdLpvK4avcLWC67Nbq0swYb0Ky4T7BkstRR6BcKaRrt389LFA0zy3w_i2XtYG\" alt=\"A picture of stars in the sky Description automatically generated\"\/><\/figure>\n<h3><em>Grouping Options<\/em><\/h3>\n<p>The longer numbers get the harder they can be to read without thousand separators, and if you need to insert them this can be done using a grouping option:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">>>> proxima_centauri = 40208000000000\n>>> f'The closest star to our own is {proxima_centauri:,} km away.' 'The closest star to our own is 40,208,000,000,000 km away.'<\/pre>\n<p>You can also use an underscore as the separator if you prefer:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">>>> f'The closest star to our own is {proxima_centauri:_} km away.' 'The closest star to our own is 40_208_000_000_000 km away.'<\/pre>\n<h3><em><br \/><\/em><em>Putting It All Together<\/em><\/h3>\n<p>You probably won\u2019t need to use a wide variety of format specification values with a single expression that often, but if you do want to put several together the order is important.<\/p>\n<p>Staying with the astronomical theme, for demonstration purposes we\u2019ll now show the distance between the Sun and Neptune in millions of kilometers:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">>>> neptune = \"Neptune\"\n>>> n_dist = 4_498_252_900 \/ 1_000_000\n>>> print(f\"|{neptune:^15}|\\n|{n_dist:~^15,.1f}|\")\n| Neptune |\n|~~~~4,498.3~~~~|<\/pre>\n<p>As you can see, reading from right to left we need to place the n_dist format specification values in the following order:<\/p>\n<ol>\n<li><strong>Type\u00a0 <\/strong>\u2013 f defines that the value should be displayed using fixed-point notation<\/li>\n<li><strong>Precision <\/strong>\u2013 .1 indicates that a single decimal place should be used\u00a0<\/li>\n<li><strong>Grouping <\/strong>\u2013 , denotes that a comma should be used as the thousand separator<\/li>\n<li><strong>Width <\/strong>\u2013 15<em> <\/em>is set as the minimum number of characters<\/li>\n<li><strong>Align <\/strong>\u2013 ^<em> <\/em>defines that the value should be centered<\/li>\n<li><strong>Fill <\/strong>\u2013 ~<em> <\/em>indicates that a tilde should occupy any unused space<\/li>\n<\/ol>\n<p>In general, format values that are not required can simply be omitted. However, if a fill value is specified without a corresponding alignment option a ValueError will be raised.<\/p>\n<h2>Final Thoughts and Further Reading<\/h2>\n<p>The examples shown in this article have been greatly simplified to demonstrate features in a straightforward way, but I hope they have provided some food for thought, enabling you to envisage ways that the Format Specification Mini-Language could be applied in real world projects.<\/p>\n<p>Basic columns have been used to demonstrate aspects of format specification, and displaying tabular information as part of a Command Line Application is one example of the ways this kind of formatting could be employed.&nbsp;<\/p>\n<p>If you want to work with and display larger volumes of data in table format though, you would do well to check out the excellent tools provided by the pandas library, which you can read about in these <a href=\"https:\/\/blog.finxter.com\/category\/pandas-library\/\" target=\"_blank\" rel=\"noreferrer noopener\">Finxter articles<\/a>.<\/p>\n<p>Also, if you would like to see the full list of available format specification values they can be found in this section of the <a href=\"https:\/\/docs.python.org\/3\/library\/string.html#format-specification-mini-language\" target=\"_blank\" rel=\"noreferrer noopener\">official Python documentation<\/a>.<\/p>\n<p>The best way to really get the hang of how format specifiers work is to do some experimenting with them yourself. Give it a try \u2013 I\u2019m sure you\u2019ll have some fun along the way!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Python provides fantastic string formatting options, but what if you need greater control over how values are presented? That\u2019s where format specifiers come in.&nbsp; This article starts with a brief overview of the different string formatting approaches. We\u2019ll then dive straight into some examples to whet your appetite for using Python\u2019s Format Specification Mini-Language in [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[857],"tags":[73,468,528],"class_list":["post-117363","post","type-post","status-publish","format-standard","hentry","category-python-tut","tag-programming","tag-python","tag-tutorial"],"_links":{"self":[{"href":"https:\/\/sickgaming.net\/blog\/wp-json\/wp\/v2\/posts\/117363","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/sickgaming.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/sickgaming.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/sickgaming.net\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/sickgaming.net\/blog\/wp-json\/wp\/v2\/comments?post=117363"}],"version-history":[{"count":0,"href":"https:\/\/sickgaming.net\/blog\/wp-json\/wp\/v2\/posts\/117363\/revisions"}],"wp:attachment":[{"href":"https:\/\/sickgaming.net\/blog\/wp-json\/wp\/v2\/media?parent=117363"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/sickgaming.net\/blog\/wp-json\/wp\/v2\/categories?post=117363"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/sickgaming.net\/blog\/wp-json\/wp\/v2\/tags?post=117363"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}