Addon.xml: Difference between revisions

From Official Kodi Wiki
Jump to navigation Jump to search
(Clean up the first half of this article)
Line 2: Line 2:
<br />
<br />
{{frodo updated}}
{{frodo updated}}
= Introduction =
= Introduction =


Each skin or script/plugin in XBMC contains the addon.xml file which sets up an overview of the addon and provides credits, versioning information and dependencies.
Every skin, script, or plugin in XBMC contains an <code>addon.xml</code> file which describes the add-on, providing credits, version information and dependencies. Below, we will explain how this file is structured and which elements must be used to create an add-on for XBMC. You can also consult the examples at the end to see how this file is laid out depending on if you are developing a skin or script/plugin.
Below we will explain which elements must be used to create an addon to be used in XBMC. At the end we will show you two different layouts to be used depending if you are developing a skin or script/addon.
 
= Overview of addon.xml =
 
Every <code>addon.xml</code> file has the same basic structure:


<syntaxhighlight lang="xml">
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<addon id="your.addon.id" name="Your Add-on" version="1.2.3" provider-name="You">
  <requires>
    <import addon="xbmc.python" version="2.1.0"/>


  </requires>
  <extension point="xbmc.python.pluginsource" library="addon.py">
    <provides>video</provides>
  </extension>
  <extension point="xbmc.addon.metadata">
    <summary lang="en">Your add-on's summary</summary>
    <description lang="en">Your add-on's description</description>
    <disclaimer lang="en"></disclaimer>
    <language></language>
    <platform>all</platform>
    <license></license>
    <forum></forum>
    <website></website>
    <email></email>
    <source></source>
  </extension>
</addon>
</syntaxhighlight>


There are a few important things to note in the above sample:


= Overview of the addon.xml items =
* The <code><addon></code> element must be present, and be the root node. It presents data about the add-on package as a whole.
There are a few things to notice:
* Inside the <code><addon></code> element is a <code><requires></code> element, listing all the dependencies that this add-on needs in order to function.
* The <addon> element must be present, and is used to present the data about the addon package as a whole.
* Then there are one or more <code><extension></code> elements, each of which describes a part of XBMC that the add-on extends.
* Inside the <addon> element is a <requires> element, listing the requirements that this addon needs in order to function.
* Finally, there is a specific <code><extension></code> element that extends <code>"xbmc.addon.metadata"</code>. This describes the add-on to the user.
* Then there is one or more <extension> elements, each of which describes which part of XBMC the addon extends.
* Finally, there is a specific <extension> element which describes the addon for the user.


== Mandatory ==
= Elements =
   
   
=== The <addon> element ===
== <addon> ==


The addon element has 4 attributes: id, version, name, and provider-name.
The <code><addon></code> element has 4 attributes, all required: <code>id</code>, <code>version</code>, <code>name</code>, and <code>provider-name</code>. For example:
* The id attribute is the unique identifier used for this add-on.  It must be unique, and must use only lowercase characters, periods, underscores, dashes and numbers.  This identifier is also used as the name of the folder that contains the add-on, so for ease of searching, we suggest you use something like <type>.<uniquename>.
* The version attribute is used by XBMC to determine whether updates are available. This should be following the  X.Y.Z (Major.Minor.Patch)  version numbering for example: '''version="0.0.1"''' Most commonly you start with a '''0.y.z''' for testing purpose and once you feel it is ready you go to '''version="1.0.0"'''
* The name attribute is the name of the add-on as it appears in the UI.  This should be in English where it makes sense for it to be so, and is not translatable.
* The provider-name attribute is used as the author field.  This could be a team of authors or a single author.
* If it's maintained by multiple people please separate them by using a komma sign  ,


Example:
<source lang="xml">
<source lang="xml">
    <addon id="script.hello.world" name="Hello World" version="0.0.1" provider-name="Dev1, Dev2">
<addon id="script.hello.world" name="Hello World" version="0.0.1" provider-name="Dev1, Dev2">
</source>
</source>


=== id attribute ===
The id attribute is the unique identifier used for this add-on.  It must be unique, and must use only lowercase characters, periods, underscores, dashes and numbers.  This identifier is also used as the name of the folder that contains the add-on, so for ease of searching, we suggest you use something like <type>.<uniquename>.
=== version attribute ===
The version attribute is used by XBMC to determine whether updates are available. This should be use a version scheme like <code>x.y.z</code> (major.minor.patch). For example: <code>version="0.0.1"</code>. Generally, you'll start with a version of <code>0.y.z</code> for test releases and once you feel it is ready for a full release, you'd bump the version to <code>1.0.0</code>.
==== How versioning works ====
* <code>2.2.1</code> is newer than <code>2.2.9</code>
* <code>2.3</code>  is newer than <code>2.2.9</code>
* <code>2.3.0</code> is newer than <code>2.2</code>
* <code>2.2.1</code> is older than <code>2.2.1b</code> ''(only one character => newer version)''
* <code>2.2.1</code> is newer than <code>2.2.1bc</code> ''(two or more characters => older version)''
* <code>2.2.1</code> is newer than <code>2.2.1 beta</code>
* <code>2.2.1</code> is newer than <code>2.2.1beta</code>
{{tip|Text should only be added for a beta or release version. In other cases version number should only contain numbers.}}
=== name attribute ===


'''How versioning works:'''
The name attribute is the name of the add-on as it appears in the UI. This should be in English where it makes sense for it to be so, and is not translatable.
* 2.2.1 is newer than 2.2.9
* 2.3 is newer than 2.2.9
* 2.3.0 is newer than 2.2
* 2.2.1 is older than 2.2.1b    << only one character = newer version
* 2.2.1 is newer than 2.2.1bc    << two or more = older version
* 2.2.1 is newer than 2.2.1 beta
* 2.2.1 is newer than 2.2.1beta


{{tip|Text should only be added in case of beta or release version. In other cases version number should only contain numbers.}}
=== provider-name attribute ===


=== The <requires> element ===
The provider-name attribute is used as the author field.  This could be a team of authors or a single author. If the add-on is maintained by multiple people please separate them with a comma (<code>,</code>).


The requires element contains one or more <import> elements which specify which other add-ons this particular add-on requires, and which version of those add-ons it requires. These add-ons may be part of XBMC itself, or may be parts of other 3rd party add-ons.
== <requires> ==


XBMC will only allow the add-on to be run if suitable versions of the non-optional add-ons on which this add-on depends are installed. When a user installs your add-on from an online repository via XBMC's add-on manager, XBMC attempts to resolve these dependencies, and install anything that your add-on relies on first. The dependency must be provided with the minimum version number your script/skin requires.
The <code><requires></code> element contains one or more <code><import></code> elements which specify which other add-ons this particular add-on requires, and which version of those add-ons it requires. These add-ons may be part of XBMC itself, or may be parts of other third-party add-ons.


The requirement may be made optional by setting the optional attribute to true. This will only install the dependency when the depending addon actually needs it. If this dependency is missing the depending addon will still be able to be installed.
XBMC will only allow the add-on to be run if suitable versions of the (non-optional) add-ons on which this add-on depends are installed. When a user installs your add-on from an online repository via XBMC's add-on manager, XBMC attempts to resolve these dependencies, and install anything that your add-on relies on first. The dependency must be provided with the minimum version number your script/skin requires.


If your module relies on third party modules, they must be installed prior to installing your
=== Examples ===
module, by the user. Assuming the third party module is available on an existing repository,
 
XBMC will install this automatically when the user installs your addon. Libraries outside of the
Here is a sample <code><requires></code> block that imports two required modules and one optional one:
xbmc domain must be loaded by your code and do not form part of the <requires> statement as
XBMC doesn't know what to do with them.


* Example of <requires> element:
<source lang="xml">
<source lang="xml">
     <requires>
     <requires>
Line 68: Line 99:
</source>
</source>


* For example this will only install on OPENELEC:
Here's another example, which will only install on OpenELEC:
 
<source lang="xml">
<source lang="xml">
     </requires>
     </requires>
Line 75: Line 107:
</source>
</source>


* Example of an optional <requires> element:
== <import> ==
<source lang="xml">
 
    <import addon="script.module.simplejson"    version="2.0.10" optional="true"/>
Each <code><import></code> element describes one dependency for an add-on, with two required attributes: <code>addon</code> and <code>version</code>. There is also an optional attribute called, fittingly, <code>optional</code>.
</source>
 
If your add-on relies on other third-party add-ons, XBMC will automatically install them as well, provided they are available on an existing add-on repository. If they aren't available on any existing repository, the user must install the other add-ons themselves. Note that you need to include any Python libraries you need directly in your add-on; these can't be loaded with an <code><import></code> element, since XBMC wouldn't know what to do with them.
 
=== addon attribute ===
 
The <code>addon</code> attribute specifies the id of the required add-on, e.g. <code>script.module.elementtree</code>.
 
=== version attribute ===


The <code>version</code> attribute specifies the minimum version of the required add-on to be installed.


=== Dependency versions ===
==== Dependency versions ====


Each different XBMC version might require you to use a higher version of the xbmc.* addon dependencies to control on which version of XBMC the addon can be installed.
Each different XBMC version might require you to use a higher version of the <code>xbmc.*</code> add-on dependencies to control on which version of XBMC the add-on can be installed.


{| class="wikitable" border="1"
{| class="wikitable" border="1"
Line 98: Line 138:
|}
|}


=== The <extension> elements ===
=== optional attribute ===
 
The dependency may be made optional by setting the <code>optional</code> attribute to <code>true</code>. This will only install the dependency when the add-on actually needs it. Even if this dependency is missing, the add-on can still be installed.


The extension element describes the technical aspects of this add-on. It will have at least a point attribute which will give the part of XBMC that the add-on extends. For instance, the addon.xml file for the Confluence skin extends the "xbmc.gui.skin" part of XBMC. All available extension points are given below.
== <extension> ==
 
The <code><extension></code> element describes the technical aspects of this add-on. It will have at least a point attribute which will give the part of XBMC that the add-on extends. For instance, the addon.xml file for the Confluence skin extends the "xbmc.gui.skin" part of XBMC. All available extension points are given below.


The various extension points that XBMC provides are given in the list below.
The various extension points that XBMC provides are given in the list below.
Line 155: Line 199:
Add-ons that don't correspond to a specific add-on category can not be installed by users. These are usually supporting or shared add-ons that are installed automatically by the add-ons that require them.
Add-ons that don't correspond to a specific add-on category can not be installed by users. These are usually supporting or shared add-ons that are installed automatically by the add-ons that require them.


==== xbmc.python.pluginsource ====
=== xbmc.python.pluginsource ===


The most common extension point that will be used by plugin addon developers is
The most common extension point that will be used by plugin addon developers is
Line 178: Line 222:
More info on [[Plugin Sources]]
More info on [[Plugin Sources]]


=== The xbmc.addon.metadata extension ===
=== xbmc.addon.metadata ===


This special extension point must be provided by all add-ons, and is the way that your add-on is described to users of the XBMC add-on manager.
This special extension point must be provided by all add-ons, and is the way that your add-on is described to users of the XBMC add-on manager.
Line 305: Line 349:
This allows you to just put any window files that do not require special treatment for 16x9 resolutions etc. in the <defaultresolution> folder, preventing needless repetition.
This allows you to just put any window files that do not require special treatment for 16x9 resolutions etc. in the <defaultresolution> folder, preventing needless repetition.


 
= Examples =
 
== Overview of the script/plugin specific items ==
 
INFO HERE
 
 
 
= addon.xml examples =


== addon.xml for skins ==
== addon.xml for skins ==
Line 385: Line 421:
</syntaxhighlight>
</syntaxhighlight>


= XBMC source code =
= Schema Definition =


addon.xml is handled in following [https://github.com/xbmc/xbmc/blob/master/addons/xbmc.addon/metadata.xsd XML Schema Definition]
The XML schema definition for <code>addon.xml</code> is located [https://github.com/xbmc/xbmc/blob/master/addons/xbmc.addon/metadata.xsd here].


[[Category:Add-ons]]
[[Category:Add-ons]]

Revision as of 04:02, 11 December 2013

Home icon grey.png   ▶ Development ▶ Add-on development ▶ Addon.xml


Introduction

Every skin, script, or plugin in XBMC contains an addon.xml file which describes the add-on, providing credits, version information and dependencies. Below, we will explain how this file is structured and which elements must be used to create an add-on for XBMC. You can also consult the examples at the end to see how this file is laid out depending on if you are developing a skin or script/plugin.

Overview of addon.xml

Every addon.xml file has the same basic structure:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<addon id="your.addon.id" name="Your Add-on" version="1.2.3" provider-name="You">
  <requires>
    <import addon="xbmc.python" version="2.1.0"/>

  </requires>
  <extension point="xbmc.python.pluginsource" library="addon.py">
    <provides>video</provides>
  </extension>
  <extension point="xbmc.addon.metadata">
    <summary lang="en">Your add-on's summary</summary>
    <description lang="en">Your add-on's description</description>
    <disclaimer lang="en"></disclaimer>
    <language></language>
    <platform>all</platform>
    <license></license>
    <forum></forum>
    <website></website>
    <email></email>
    <source></source>
  </extension>
</addon>

There are a few important things to note in the above sample:

  • The <addon> element must be present, and be the root node. It presents data about the add-on package as a whole.
  • Inside the <addon> element is a <requires> element, listing all the dependencies that this add-on needs in order to function.
  • Then there are one or more <extension> elements, each of which describes a part of XBMC that the add-on extends.
  • Finally, there is a specific <extension> element that extends "xbmc.addon.metadata". This describes the add-on to the user.

Elements

<addon>

The <addon> element has 4 attributes, all required: id, version, name, and provider-name. For example:

<addon id="script.hello.world" name="Hello World" version="0.0.1" provider-name="Dev1, Dev2">

id attribute

The id attribute is the unique identifier used for this add-on. It must be unique, and must use only lowercase characters, periods, underscores, dashes and numbers. This identifier is also used as the name of the folder that contains the add-on, so for ease of searching, we suggest you use something like <type>.<uniquename>.

version attribute

The version attribute is used by XBMC to determine whether updates are available. This should be use a version scheme like x.y.z (major.minor.patch). For example: version="0.0.1". Generally, you'll start with a version of 0.y.z for test releases and once you feel it is ready for a full release, you'd bump the version to 1.0.0.

How versioning works

  • 2.2.1 is newer than 2.2.9
  • 2.3 is newer than 2.2.9
  • 2.3.0 is newer than 2.2
  • 2.2.1 is older than 2.2.1b (only one character => newer version)
  • 2.2.1 is newer than 2.2.1bc (two or more characters => older version)
  • 2.2.1 is newer than 2.2.1 beta
  • 2.2.1 is newer than 2.2.1beta
Tip Tip: Text should only be added for a beta or release version. In other cases version number should only contain numbers.

name attribute

The name attribute is the name of the add-on as it appears in the UI. This should be in English where it makes sense for it to be so, and is not translatable.

provider-name attribute

The provider-name attribute is used as the author field. This could be a team of authors or a single author. If the add-on is maintained by multiple people please separate them with a comma (,).

<requires>

The <requires> element contains one or more <import> elements which specify which other add-ons this particular add-on requires, and which version of those add-ons it requires. These add-ons may be part of XBMC itself, or may be parts of other third-party add-ons.

XBMC will only allow the add-on to be run if suitable versions of the (non-optional) add-ons on which this add-on depends are installed. When a user installs your add-on from an online repository via XBMC's add-on manager, XBMC attempts to resolve these dependencies, and install anything that your add-on relies on first. The dependency must be provided with the minimum version number your script/skin requires.

Examples

Here is a sample <requires> block that imports two required modules and one optional one:

    <requires>
      <import addon="xbmc.python"                 version="2.1.0"/>
      <import addon="script.module.elementtree"   version="1.2.7"/>
      <import addon="script.module.simplejson"    version="2.0.10" optional="true"/>
    </requires>

Here's another example, which will only install on OpenELEC:

    </requires>
        <import addon="os.openelec.tv" version="2.0" optional="false"/>
    </requires>

<import>

Each <import> element describes one dependency for an add-on, with two required attributes: addon and version. There is also an optional attribute called, fittingly, optional.

If your add-on relies on other third-party add-ons, XBMC will automatically install them as well, provided they are available on an existing add-on repository. If they aren't available on any existing repository, the user must install the other add-ons themselves. Note that you need to include any Python libraries you need directly in your add-on; these can't be loaded with an <import> element, since XBMC wouldn't know what to do with them.

addon attribute

The addon attribute specifies the id of the required add-on, e.g. script.module.elementtree.

version attribute

The version attribute specifies the minimum version of the required add-on to be installed.

Dependency versions

Each different XBMC version might require you to use a higher version of the xbmc.* add-on dependencies to control on which version of XBMC the add-on can be installed.

Current versions
XBMC version xbmc.python xbmc.gui xbmc.json xbmc.metadata xbmc.addon
Dharma 10.1 Deprecated 1.0 2.11 2.0 1.0 0.1
Eden 11.0 2.0 3.0 4.0 1.0 11.0
Frodo 12.0 & 12.1 & 12.2 2.1.0 4.0.0 6.0.0 2.1.0 12.0.0
Gotham 13.0 2.12.0 5.0.1 6.6.0 2.1.0 12.0.0

optional attribute

The dependency may be made optional by setting the optional attribute to true. This will only install the dependency when the add-on actually needs it. Even if this dependency is missing, the add-on can still be installed.

<extension>

The <extension> element describes the technical aspects of this add-on. It will have at least a point attribute which will give the part of XBMC that the add-on extends. For instance, the addon.xml file for the Confluence skin extends the "xbmc.gui.skin" part of XBMC. All available extension points are given below.

The various extension points that XBMC provides are given in the list below.

Extension point Addon Category
xbmc.gui.skin Skin
xbmc.gui.webinterface Web interface
xbmc.addon.repository <None>
xbmc.service Services
xbmc.metadata.scraper.albums Album information
xbmc.metadata.scraper.artists Artist information
xbmc.metadata.scraper.movies Movie information
xbmc.metadata.scraper.musicvideos Music video information
xbmc.metadata.scraper.tvshows TV information
xbmc.metadata.scraper.library <None>
xbmc.ui.screensaver Screensaver
xbmc.player.musicviz Visualization
xbmc.python.pluginsource Music Add-ons (audio) / Picture Add-ons (image) / Program Add-ons (executable) / Video Add-ons (video)
xbmc.python.script Music Add-ons (audio) / Picture Add-ons (image) / Program Add-ons (executable) / Video Add-ons (video)
xbmc.python.weather Weather
xbmc.python.subtitles (Future Gotham removal) Subtitles
xbmc.subtitle.module (Future Gotham addition) Subtitle service module
xbmc.python.lyrics Lyrics
xbmc.python.library <None>
xbmc.python.module These don't show up in the addon browser and are purely as support for other scripts.
xbmc.addon.video Video Add-ons (video)
xbmc.addon.audio Music Add-ons (audio)
xbmc.addon.image Picture Add-ons (image)

Add-ons that don't correspond to a specific add-on category can not be installed by users. These are usually supporting or shared add-ons that are installed automatically by the add-ons that require them.

xbmc.python.pluginsource

The most common extension point that will be used by plugin addon developers is "xbmc.python.pluginsource" .

The <extension point="xbmc.python.pluginsource"> tag has an extra attribute "library". This is the name of the python script (startup script) that will be run when the plugin is activated. This file must exist in the root of your addon directory. The extension has an addition sub element <provides> and is a whitespace separated list of image, video, audio, executable. This determines in what area (or context) of the XBMC system your addon will make itself visible in.

  • image => Pictures
  • video => Video
  • audio => Music
  • executable => Programs
  • <blank> => No visible presence

Example:

    <extension point="xbmc.python.pluginsource" library="gpodderxbmc.py">
        <provides>audio video</provides>
    </extension>

More info on Plugin Sources

xbmc.addon.metadata

This special extension point must be provided by all add-ons, and is the way that your add-on is described to users of the XBMC add-on manager.

Required information

There are several elements that this should contain and all are compulsory (except the broken tag). Each of the elements below must always be present in English as a minmum.:

  • One or more summary elements provide a short summary of what the add-on does. This should be a single sentence. It may be translated into multiple languages, whereby each has a lang="ch" attribute. No lang attribute indicates English but is recommended.
<summary lang="en">Hello World script provides some basic examples on how to create your first script.</summary>


  • One or more description elements provide a more detailed summary of what the add-on does. Again, these can be translated.
<description lang="en">Hello World script provides some basic examples on how to create your first script
 and hopefully will increase the number of XBMC users to start creating their own addons.</description>


  • One or more disclaimer elements that indicate what (if any) things the user should know about the add-on. There is no need to have a disclaimer if you don't want one, though if something requires settings, or only works in a particular country then you may want to state this here.
<disclaimer lang="en">Feel free to use this script. For information visit the wiki.</disclaimer>


  • A platform tag which specifies which platforms (operating systems, hardware) this add-on runs on. Many add-ons will run on all platforms, so "all" is an option. If the platform tag is missing, we assume the add-on runs on all platforms. A combination of these is also possible. Currently available options are:
  • all
  • linux
  • osx
  • osx64
  • osx32
  • ios
  • windx
  • wingl
  • android
<platform>all</platform>


  • Language tag(s). These are the language(s) of the *content* provided by your add-on. it applies to plugins, scripts, scrapers etc. This allows browsing the add-on list by language. When there is no specific language provided in your content leave it blank.

List of language codes (ISO-639:1988)

    <language>en de fr</language>
    or
    <language></language>


  • Broken tag. This will mark the add-on as broken in the XBMC repo with providing the reason why. You don't need to do a version bump for this to work.
    <broken>deprecated</broken>

Required additional information

These tags will be used to provide easy navigation on our upcoming add-on front-end where you can browse through available add-ons and directly visit the forum thread, source code or contact the add-on author.


  • License tag that indicate what license is used for this add-on.
    <license>GNU GENERAL PUBLIC LICENSE. Version 2, June 1991</license>
  • Forum tag. This this provide the forum thread URL for this specific add-on.
    <forum>put URL here</forum>
    <forum></forum>
  • Website tag. This provides the website URL for this specific add-on.
    <website>put URL here</website>
  • Source tag. This provides the source code location URL for this specific add-on.
    <source>put URL here</source>
  • E-mail tag. This provides the e-mail adress of the author if he wishes to do so for this specific add-on. Here are two examples of how you can make it look (the second one it harder for spambots to use). NOTE: e-mail address can be left blank if you do not want to make it public.
    <email>[email protected]</email>
    <email>foo at bar dot com</email>
    <email></email>

Skin specific elements

Overview

defaultresolution Default resolution folder for this skin. This is the base directory that all window xml file requests will fall back to.
defaultresolutionwide Default widescreen resolution folder for this skin. This is the directory that all window xml file requests from widescreen resolutions (1080i, 720p, 480p 16x9, NTSC 16x9 and PAL 16x9) will fallback to. If the file isn't found in this window, then it'll fall back to the <defaultresolution> folder.
defaultthemename Default theme name. Currently set to: Default.
effectslowdown A multiplier that is applied to all <animation> effect lengths in the skin. Useful to slow down all animations globally so that you can better configure timings and see interactions between animating controls.
debugging When set to true, it'll display onscreen debug information (xml filename, mouse position and focused control type and name) in the skin.
res Support for arbitrary skin resolutions.

How window xml files are found

XBMC can run in many differing resolutions, and a skin should try and cater to all these resolutions. The easiest way is to develop for one specific resolution and make sure that all controls contain <width> and <height> tags. That way, XBMC can scale the controls to the new screen resolution.

However, you may choose to develop alternative window xml files for differing resolutions (such as for HDTV resolutions, or for widescreen versus 4x3 resolutions).

The order that XBMC looks for it's skin files are as follows:

  1. It first looks in the current screenmode folder (one of 1080i, 720p, NTSC16x9, NTSC, PAL16x9 or PAL)
  2. If the current screenmode is 1080i, it then looks in the 720p folder.
  3. If the current screenmode is a widescreen mode (1080i, 720p, NTSC16x9, PAL16x9) then it looks in the <defaultresolutionwide> folder.
  4. Finally, it looks in the <defaultresolution> folder.

This allows you to just put any window files that do not require special treatment for 16x9 resolutions etc. in the <defaultresolution> folder, preventing needless repetition.

Examples

addon.xml for skins

<?xml version="1.0" encoding="UTF-8"?>
<addon
  id="skin.confluence"
  version="2.1.3"
  name="Confluence"
  provider-name="Jezz_X, Team XBMC">
  <requires>
    <import addon="xbmc.gui" version="4.0.0"/>
  </requires>
  <extension
    point="xbmc.gui.skin"
    defaultthemename="textures.xbt"
    debugging="false"
    effectslowdown="0.75">
    <res width="1280" height="720" aspect="16:9" default="true" folder="720p" />
  </extension>
  <extension point="xbmc.addon.metadata">
    <summary lang="en">Confluence skin by Jezz_X. (XBMC's default skin)</summary>
    <description lang="en">Confluence is the default skin for XBMC 9.11 and above. It is a combination of concepts from many popular skins, and attempts to embrace and integrate their good ideas into a skin that should be easy for first time XBMC users to understand and use.</description>
    <disclaimer lang="en">Confluence is the default skin for XBMC, removing it may cause issues</disclaimer>
    <platform>all</platform>
    <license>GNU GENERAL PUBLIC LICENSE. Version 2, June 1991</license>
    <forum></forum>
    <website></website>
    <email></email>
    <source></source>
  </extension>
</addon>

One thing to note is that all tag names are lower case. XML tag names are case sensitive!

addon.xml for scripts/plugins

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<addon
    id="script.artwork.downloader"
    name="Artwork Downloader"
    version="12.0.12"
    provider-name="Martijn">
  <requires>
    <import addon="xbmc.python"                 version="2.1.0"/>
    <import addon="xbmc.json"                   version="6.0.0"/>
    <import addon="xbmc.addon"                  version="12.0.0"/>
    <import addon="script.module.elementtree"   version="1.2.7"/>
    <import addon="script.module.simplejson"    version="2.0.10" optional="true"/>
    <import addon="script.common.plugin.cache"  version="1.3.0"/>
  </requires>
  <extension point="xbmc.python.script"         library="default.py">
    <provides>executable</provides>
  </extension>
  <extension point="xbmc.service" library="service.py" start="login"/>
  <extension point="xbmc.addon.metadata">
    <summary lang="en">Downloads Artwork for TV shows, Movies and Musicvideos in your library</summary>
    <description lang="en">Downloads all available artwork for TV shows, Movies and Musicvideos in your library. Check the options for supported artwork[CR]Artwork sources:[CR]www.fanart.tv[CR]www.thetvdb.com[CR]www.themoviedb.org[CR]Remark:[CR]Check your skin to see what type of artwork is supported![CR]Each TV Show/Movie must have its own folder![CR]Skin integration:[CR]See readme file</description>
    <disclaimer lang="en">For bugs, requests or general questions visit the Artwork Downloader thread on the XBMC forum.</disclaimer>
    <language></language>
    <platform>all</platform>
    <license>GNU GENERAL PUBLIC LICENSE. Version 2, June 1991</license>
    <forum></forum>
    <website></website>
    <email></email>
    <source></source>
  </extension>
</addon>

Schema Definition

The XML schema definition for addon.xml is located here.