Template:ASIN/doc: Difference between revisions
→When to use: clarify remove |
Deleatur yhe (talk | contribs) m 1 revision imported |
(No difference)
| |
Latest revision as of 10:13, 9 September 2026
| This is a documentation subpage for Template:ASIN. It may contain usage information, categories and other content that is not part of the original template page. |
__EXPECTED_UNCONNECTED_PAGE__
| This template is used on approximately 5,000 pages and changes may be widely noticed. Test changes in the template's /sandbox or /testcases subpages, or in your own user subpage. Consider discussing changes on the talk page before implementing them. |
When to use
This is "an identifier of last resort". Almost any other identifier, such as {{ISBN}}, {{doi}}, {{OCLC}}, {{LCCN}}, etc., is a better choice and should be used instead of this one.
If the ASIN begins with a number, it is a standard ISBN; please use {{ISBN|xxxxxxxxxx}} and remove {{ASIN|xxxxxxxxxx}}, as this will allow us to link to other sites as well as Amazon.
Maintenance categories
- Category:Articles using Template:ASIN with an all-numeric value (0): Articles in this category are likely to have ASIN templates that can be converted to:
After conversion, always check the resulting link to ensure that it links to the intended item.
How to use
<syntaxhighlight lang="wikitext"> ASIN [https://www.amazon.com/dp/asin_id_from_Amazon asin_id_from_Amazon ]</syntaxhighlight>
The usage structure above is written for easy reading. You must not have linebreaks or spaces between the parameters.
Examples
{{ASIN|B00086U61Y}}
- ASIN B00086U61Y
- (note it uses amazon.com by default)
- Add
country=uk/de/fr/etc., in order to use their local Amazon sites (the template adds .co or .com before the country code as needed, so only the country code itself needs to be specified):{{ASIN|B000F8S4A0|country=uk}}
- ASIN B000F8S4A0
- (note this time it uses amazon.co.uk)
{{ASIN|B00M262M1A|country=fr}}
- ASIN B00M262M1A
- (note this time it uses amazon.fr)
- And here's an item with a supplied title:
{{ASIN|B00086U61Y|title=Item's Title}}- ASIN B00086U61Y, Item's Title
- Here's an item with a supplied date:
{{ASIN|B00086U61Y|date=2000-12-24}}- ASIN B00086U61Y (2000-12-24)
- Here's an item with a supplied title and date:
{{ASIN| B00086U61Y|title=Item's Title|date=2000-12-24}}- ASIN B00086U61Y, Item's Title (2000-12-24)
- Here's an item from the UK with a supplied title and date:
{{ASIN|B00086U61Y|country=uk|title=Item's Title|date=2000-12-24}}- ASIN B00086U61Y, Item's Title (2000-12-24)
TemplateData
TemplateData for ASIN
<templatedata> { "params": { "1": { "label": "ASIN", "description": "ASIN identifier", "example": "B00086U61Y", "type": "string", "required": true }, "title": { "label": "Title", "description": "Title of the item", "example": "Example Book Title", "type": "string" }, "country": { "label": "Country code", "description": "country code to change the URL from .com to (e.g.) .co.uk", "example": "uk", "type": "string" }, "date": { "label": "Date", "description": "Date", "example": "2020-12-14", "type": "string" } }, "description": "Use this template to create a link (or list of links) to Amazon.com using an item's ASIN identifier." } </templatedata>