Skip to content

Developers

How can we help you?

← Go back

Right

BeBanjo’s rights represent the time window in which a content can be displayed. They apply on a feature, a clip or a series and they might be part of a deal or not.

This is how an archive right looks like:

<?xml version="1.0" encoding="UTF-8"?>
<right>
  <id type="integer">4</id>
  <external-id>RR12-4</external-id>
  <name>Rule RR12</name>
  <right-type>archive</right-type>
  <starts type="datetime">2010-10-10T00:00:00Z</starts>
  <ends type="datetime">2011-10-10T00:00:00Z</ends>
  <episode-selection-type>except</episode-selection-type>
  <episode-selection>1,7-9</episode-selection>
  <clearances-included type="boolean">true</clearances-included>
  <utility-limit type="integer">3</utility-limit>
  <repeats type="boolean">false</repeats>
  <minimum-exploitation type="integer">10</minimum-exploitation>
  <maximum-exploitation type="integer">30</maximum-exploitation>
  <exploitation-limits-context>total</exploitation-limits-context>
  <rerun-limit type="integer">5</rerun-limit>
  <parity>start+end</parity>
  <link rel="self" href="https://movida.bebanjo.net/api/rights/4"/>
  <link rel="licensable" href="https://movida.bebanjo.net/api/title_groups/1"/>
  <link rel="licensor" href="https://movida.bebanjo.net/api/licensors/114"/>
  <link rel="granted_requirements" href="https://movida.bebanjo.net/api/rights/4/granted_requirements"/>
  <link rel="specific_platforms" href="https://movida.bebanjo.net/api/rights/4/specific_platforms"/>
  <link rel="sourced_schedulings" href="https://movida.bebanjo.net/api/rights/4/sourced_schedulings"/>
  <link rel="note" href="https://movida.bebanjo.net/api/rights/4/note"/>
  <link rel="metadata" href="https://movida.bebanjo.net/api/rights/4/metadata"/>
</right>
{
  "resource_type": "right",
  "id": 4,
  "external_id": "RR12-4",
  "name": "Rule RR12",
  "right_type": "archive",
  "starts": "2010-10-10T00:00:00Z",
  "ends": "2011-10-10T00:00:00Z",
  "episode_selection_type": "except",
  "episode_selection": "1,7-9",
  "clearances_included": true,
  "utility_limit": 3,
  "repeats": false,
  "minimum_exploitation": 10,
  "maximum_exploitation": 30,
  "exploitation_limits_context": "total",
  "rerun_limit": 5,
  "parity": "start+end",
  "self_link": "https://movida.bebanjo.net/api/rights/4",
  "licensable_link": "https://movida.bebanjo.net/api/title_groups/1",
  "licensor_link": "https://movida.bebanjo.net/api/licensors/114",
  "granted_requirements_link": "https://movida.bebanjo.net/api/rights/4/granted_requirements",
  "specific_platforms_link": "https://movida.bebanjo.net/api/rights/4/specific_platforms",
  "sourced_schedulings_link": "https://movida.bebanjo.net/api/rights/4/sourced_schedulings",
  "note_link": "https://movida.bebanjo.net/api/rights/4/note",
  "metadata_link": "https://movida.bebanjo.net/api/rights/4/metadata"
}

This is how a Catch-up right looks like:

<right>
  <id type="integer">5</id>
  <external-id>RR12-5</external-id>
  <name>Rule RR12 (Catchup)</name>
  <right-type>catchup</right-type>
  <start-offset-value>1</start-offset-value>
  <start-offset-unit>hours</start-offset-unit>
  <start-offset-reference>after_tx_ends</start-offset-reference>
  <end-offset-value>30</end-offset-value>
  <end-offset-unit>days</end-offset-unit>
  <end-offset-reference>after_tx_ends</end-offset-reference>
  <reference-tx-nth>1</reference-tx-nth>
  <transmission-type>play_run</transmission-type>
  <reference-tx-from>2010-01-06T00:00Z</reference-tx-from>
  <reference-tx-to>2011-01-07T23:59Z</reference-tx-to>
  <episode-selection-type>except</episode-selection-type>
  <episode-selection>1,7-9</episode-selection>
  <clearances-included type="boolean">true</clearances-included>
  <utility-limit type="integer">3</utility-limit>
  <repeats type="boolean">false</repeats>
  <minimum-exploitation type="integer">10</minimum-exploitation>
  <maximum-exploitation type="integer">30</maximum-exploitation>
  <exploitation-limits-context>total</exploitation-limits-context>
  <rerun-limit type="integer">5</rerun-limit>
  <parity>start+end</parity>
  <link rel="self" href="https://movida.bebanjo.net/api/rights/5"/>
  <link rel="licensable" href="https://movida.bebanjo.net/api/title_groups/1"/>
  <link rel="reference_tx_channel" href="https://movida.bebanjo.net/api/linear_channels/2"/>
  <link rel="licensor" href="https://movida.bebanjo.net/api/licensors/114"/>
  <link rel="granted_requirements" href="https://movida.bebanjo.net/api/rights/5/granted_requirements"/>
  <link rel="specific_platforms" href="https://movida.bebanjo.net/api/rights/5/specific_platforms"/>
  <link rel="note" href="https://movida.bebanjo.net/api/rights/5/note"/>
  <link rel="metadata" href="https://movida.bebanjo.net/api/rights/5/metadata"/>
</right>
{
  "resource_type": "right",
  "id": 5,
  "external_id": "RR12-5",
  "name": "Rule RR12 (Catchup)",
  "right_type": "catchup",
  "transmission_type": "play_run",
  "reference_tx_nth": "1",
  "reference_tx_from": "2010-01-06T00:00Z",
  "reference_tx_to": "2011-01-07T23:59Z",
  "start_offset_value": 1,
  "start_offset_unit": "hours",
  "start_offset_reference": "after_tx_ends",
  "start_fixed_time": null,
  "end_offset_value": 30,
  "end_offset_unit": "days",
  "end_offset_reference": "after_tx_ends",
  "end_fixed_time": null,
  "episode_selection_type": "except",
  "episode_selection": "1,7-9",
  "clearances_included": true,
  "utility_limit": 3,
  "repeats": false,
  "minimum_exploitation": 10,
  "maximum_exploitation": 30,
  "exploitation_limits_context": "total",
  "rerun_limit": 5,
  "parity": "start+end",
  "self_link": "https://movida.bebanjo.net/api/rights/5",
  "licensable_link": "https://movida.bebanjo.net/api/title_groups/1",
  "reference_tx_channel_link": "https://movida.bebanjo.net/api/linear_channels/2",
  "licensor_link": "https://movida.bebanjo.net/api/licensors/114",
  "granted_requirements_link": "https://movida.bebanjo.net/api/rights/5/granted_requirements",
  "specific_platforms_link": "https://movida.bebanjo.net/api/rights/5/specific_platforms",
  "note_link": "https://movida.bebanjo.net/api/rights/5/note",
  "metadata_link": "https://movida.bebanjo.net/api/rights/5/metadata"
}

Valid attributes

  • id (required): BeBanjo internal identifier of the right.

  • external-id (optional): identifier of the right in the external system.

  • name (optional): name of the right, meaningful to the user. When no value is provided, BeBanjo will store a generic name based on number of rights in the licensable, such as Right #1.

  • right-type (required): type of the right. Possible values are “archive” and “catchup”.

  • clearances-included (deprecated): specified value has no effect and it will default to true.

  • utility-limit (optional): indicates the maximum number of episodes on a series that can be available to any one time. So this attribute can only be set on rights applied to series. Allowed values are: nil (if theres is no such restriction) and positive integers greater than 0.

  • repeats (optional): if not specified at creation it will defaut to false. Indicates if an episode cannot be repeated until all episodes in the series have been scheduled. So this attribute can only be set on rights applied to series. Allowed values are: true or false.

  • minimum-exploitation (optional): indicates the minimum duration in days on exploitation. Allowed values are: nil (if there is no such limit) and integer values greater or equal than 0. If a value maximum_explotation is provided too must be lower than that.

  • maximum-exploitation (optional): indicates the maximum duration in days on exploitation. Allowed values are: nil (if there is no such limit) and integer values greater or equal than 0. If a value minimum_explotation is provided too must be higher than that.

  • exploitation-limits-context (optional): this attribute only makes sense if any or both exploitation limits are set. Allowed values are: total and window. Its purpose is to specify the behaviour while applying such limits:

    • total. They will be applied as a group to all the schedule entries for each platform. This is the default behaviour.

    • window. The limits will be applied individualy for each schedule entry.

  • rerun-limit (optional): indicates the max allowed number of schedule entries in the same platform and within the availability window. Allowed values are: nil (if there is no such limit) and integer values greater or equal than 1.

  • parity (optional): indicates if schedule entries must be specified en every platform with the same: start date, end date or same start and end dates. Allowed values are: nil (if there is no such restriction), ‘start’, ‘end’, and ‘start+end’

  • episode-selection-type (optional): this attribute only makes sense for rights defined on series. Can take four different values:

    • all: the right applies to all episodes in the series.

    • all-at-once: the right applies to all episodes in the series, availability windows are applied based on the first reference program (linear scheduling). This value is only valid for catchup rights

    • only: the right applies to the episode specified in the attribute <episode-selection>.

    • except: the right applies to all episodes except those specified in the attribute <episode-selection>.

  • episode-selection (optional): this attribute only makes sense when <episode-selection-type> has the values only or except. Its purpose is to specify a range of episodes, separating the episode numbers by commas or by a dash. A dash range means that all the episodes in that range are included. Can’t be longer than 255 characters. For example:

    • 1,3-5,7,9 range includes the episodes 1, 3, 4, 5, 7 and 9

    • 1-3,9,11-13 range includes the episodes 1, 2, 3, 9, 11, 12 and 13

Archive right context

  • starts (required): timestamp representing when the right starts.

  • ends (required): timestamp representing when the right ends.

If an archive right was used as a source for schedulings, these schedulings can be accessed through the link identified with the rel="sourced_schedulings" attribute:

<?xml version="1.0" encoding="UTF-8"?>
<right>
  <!-- ... -->
  <link rel="sourced_schedulings" href="https://movida.bebanjo.net/api/rights/3/sourced_schedulings">
</right>
{
  "resource_type": "right",
  // ...
  "sourced_schedulings_link": "https://movida.bebanjo.net/api/rights/3/sourced_schedulings",
  // ...
}

Catch-up right context

  • starts (optional): timestamp representing when the right starts.

  • ends (optional): timestamp representing when the right ends.

  • start-offset-value (optional): define when the right starts. Allowed values are positive integers. If specified you need to provide <start-offset-unit> and <start-offset-reference> to define the start completely.

  • start-offset-unit (optional): define when the right starts. Allowed values are: minutes, hours, days, weeks, months, years. If specified you need to provide <start-offset-value> and <start-offset-reference> to define the start completely.

  • start-offset-reference (optional): define when the right starts. Allowed values are: before_tx_starts, after_tx_starts, after_tx_ends, after_last_episode_starts and after_last_episode_ends. If specified you need to provide <start-offset-value> and <start-offset-unit> to define the start completely.

  • start-fixed-time (optional): define when the rights starts at a given hour. Values for this field should be provided in the format “hh:mm”. This attribute can only be set when start-offset-unit is set to days, weeks, months, years.

  • end-offset-value (optional): define when the right ends. Allowed values are positive integers. If specified you need to provide <end-offset-unit> and <end-offset-reference> to define the end completely.

  • end-offset-unit (optional): define when the right ends. Allowed values are: minutes, hours, days, weeks, months, years. If specified you need to provide <end-offset-value> and <end-offset-reference> to define the end completely.

  • end-offset-reference (optional): define when the right ends. Allowed values are: after_start, after_tx_ends and after_last_episode. If specified you need to provide <end-offset-value> and <end-offset-unit> to define the end completely.

  • end-fixed-time (optional): define when the right ends at a given hour. Values for this field should be provided in the format “hh:mm”. This attribute can only be set when <end-offset-unit> is set to days, weeks, months, years.

  • reference-tx-nth (required): ordinal value representing what linear schedulings will be used. Allowed values are: all, a specific number or a range of numbers, separating the numbers by commas or by a dash. A dash range means that all the numbers in that range are included. Can’t be longer than 255 characters. When the link identified with the rel="transmission_content" attribute is present, the all value is not allowed.

  • transmission-type (required): define the transmission type criteria to select the linear scheduling that will be used. Can take the following values:
    • play_run: consider the play run number of linear schedulings, which is the transmission number of the linear schedulings across linear channels.
    • costed_run: consider the run number in contract of linear schedulings, which is the costed run of the linear schedulings across linear channels.
    • rerun: consider the number of reruns of a linear scheduling.

    Note: Deprecated feature.

    Currently when no transmission-type is specified the value play_run is taken as default. The play_run value matches the transmission selection criteria present before the transmission-type attribute was available in the API.

    Please note that this behaviour is deprecated, and you shouldn’t rely on it in your integration. In the future, you will get an error when creating a rule without explicitly setting the transmission-type to be used.

  • linear-contract-id (optional): an unique identifier for a Linear contract. It allows to target costed run and reruns for the Linear contract specified. This attribute only makes sense when <transmission-type> has the value costed_run or rerun. Can’t be longer than 255 characters.

  • include-reruns (optional): this attribute only makes sense when <transmission-type> has the value costed_run. It allows to target reruns per costed run, eg. to use linear schedulings with rerun attribute included in include-reruns value. Allowed values are: all, a specific number or a range of numbers, separating the numbers by commas or by a dash. A dash range means that all the numbers in that range are included. Can’t be longer than 255 characters.

  • reference-tx-from (optional): timestamp representing what linear schedulings will be taken into account using their begins-at attribute.

  • reference-tx-to (optional): timestamp representing what linear schedulings will be taken into account using their ends-at attribute.

Catch-up rights related to a licensable series or collection can optionally specify a different linear content through the link identified with the rel="transmission_content" attribute:

<?xml version="1.0" encoding="UTF-8"?>
<right>
  <!-- ... -->
  <link rel="transmission_content" href="https://movida.bebanjo.net/api/title_groups/3">
  <!-- ... -->
</right>
{
  "resource_type": "right",
  // ...
  "transmission_content_link": "https://movida.bebanjo.net/api/title_groups/3",
  // ...
}

All episodes or titles of the transmission content are considered when taking into account linear schedulings.

Get a list of all rights in the current account

Rights are linked from the root of the API, through the link identified with the rel="rights" attribute:

<?xml version="1.0" encoding="UTF-8"?>
<movida>
  <!-- ... -->
  <link rel="rights" href="https://movida.bebanjo.net/api/rights">
  <!-- ... -->
</movida>
{
  "resource_type": "movida",
  // ...
  "rights_link": "https://movida.bebanjo.net/api/rights",
  // ...
}

Following that link, we can fetch the list of rights in the current account.

$ curl --digest -u robot_user:password https://movida.bebanjo.net/api/rights?page=2
$ curl --digest -u robot_user:password -H "Accept: application/json" https://movida.bebanjo.net/api/rights?page=2
<?xml version="1.0" encoding="UTF-8"?>
<rights>
  <total-entries>113</total-entries>
  <link rel="next" href="https://movida.bebanjo.net/api/rights?page=1"/>
  <link rel="prev" href="https://movida.bebanjo.net/api/rights?page=3"/>
  <right>
    <id type="integer">5</id>
    <external-id>RR12-5</external-id>
    <right-type>catchup</right-type>
    <!-- ... -->
  </right>
  <right>
    <id type="integer">6</id>
    <external-id>RR11-5</external-id>
    <right-type>archive</right-type>
    <!-- ... -->
  </right>
  <!-- ... -->
<rights>
{
  "total_entries": 113,
  "prev_link": "https://movida.bebanjo.net/api/rights?page=1",
  "next_link": "https://movida.bebanjo.net/api/rights?page=3",
  "entries": [
    {
      "resource_type": "right",
      "id": 5,
      "external_id": "RR12-5",
      "name": "Right #5",
      "right_type": "catchup",
      // ...
    },
    {
      "resource_type": "right",
      "id": 6,
      "external_id": "RR12-6",
      "name": "Right #6",
      "right_type": "archive",
      // ...
    },
    // ...
  ]
}

Note: This is a paginated resource. By default, only 50 Rights will be included in each page but you can override this default by using the per_page parameter described in the next section. The total-entries attribute will indicate the total number of entries and the links rel="next" and rel="prev" should be used to get the next and the previous pages.

Valid attributes

You can filter the list of Rights returned using the following parameters:

  • external_id: It will return only the Right with the exact given external_id (if any).

  • per_page: Number of elements returned in each page. The maximum value allowed is 200 and the default is 50.

  • page: Number of the page you want to be returned.

Get a list of rights from a deal

Given an existing deal, for example:

<deal>
  <id type="integer">2</id>
  <name>Marvel Deal 2013</name>
  <external-id>Marvel2013</external-id>
  <right-type>archive</right-type>
  <starts type="datetime">2022-01-01T00:00:00Z</starts>
  <ends type="datetime">2023-01-01T00:00:00Z</ends>
  <rights-updated-at nil="true"/>
  <utility-limit nil="true"/>
  <repeats type="boolean">false</repeats>
  <minimum-exploitation nil="true"/>
  <maximum-exploitation nil="true"/>
  <exploitation-limits-context nil="true"/>
  <rerun-limit nil="true"/>
  <parity nil="true"/>
  <link rel="self" href="https://movida.bebanjo.net/api/deals/2"/>
  <link rel="rights" href="https://movida.bebanjo.net/api/deals/2/rights"/>
  <link rel="metadata" href="https://movida.bebanjo.net/api/deals/2/metadata"/>
  <link rel="granted_requirements" href="https://movida.bebanjo.net/api/deals/2/granted_requirements"/>
  <link rel="specific_platforms" href="https://movida.bebanjo.net/api/deals/2/specific_platforms"/>
</deal>
{
  "resource_type": "deal",
  "id": 2,
  "name": "Marvel Deal 2013",
  "external_id": "Marvel2013",
  "right_type": "archive",
  "starts": "2022-01-01T00:00:00Z",
  "ends": "2023-01-01T00:00:00Z",
  "rights_updated_at": null,
  "utility_limit": null,
  "repeats": false,
  "minimum_exploitation": null,
  "maximum_exploitation": null,
  "exploitation_limits_context": null,
  "rerun_limit": null,
  "parity": null,
  "self_link": "https://movida.bebanjo.net/api/deals/2",
  "rights_link": "https://movida.bebanjo.net/api/deals/2/rights",
  "metadata_link": "https://movida.bebanjo.net/api/deals/2/metadata",
  "granted_requirements_link": "https://movida.bebanjo.net/api/deals/2/granted_requirements",
  "specific_platforms_link": "https://movida.bebanjo.net/api/deals/2/specific_platforms"
}

All the rights of that deal can be obtained by following the link rel="rights":

$ curl --digest -u robot_user:password https://movida.bebanjo.net/api/deals/2/rights
$ curl --digest -u robot_user:password -H "Accept: application/json" https://movida.bebanjo.net/api/deals/2/rights
<?xml version="1.0" encoding="UTF-8"?>
<rights type="array">
  <total-entries>3</total-entries>
  <right>
    <id type="integer">4</id>
    <external-id nil="true"/>
    <name>Right #1</name>
    <right-type>archive</right-type>
    <starts type="datetime">2022-01-01T00:00:00Z</starts>
    <ends type="datetime">2023-01-01T00:00:00Z</ends>
    <clearances-included type="boolean">true</clearances-included>
    <minimum-exploitation nil="true"/>
    <maximum-exploitation nil="true"/>
    <exploitation-limits-context nil="true"/>
    <rerun-limit nil="true"/>
    <parity nil="true"/>
    <link rel="self" href="https://movida.bebanjo.net/api/rights/4"/>
    <link rel="deal" href="https://movida.bebanjo.net/api/deals/2"/>
    <link rel="licensable" href="https://movida.bebanjo.net/api/titles/1"/>
    <link rel="granted_requirements" href="https://movida.bebanjo.net/api/rights/4/granted_requirements"/>
    <link rel="specific_platforms" href="https://movida.bebanjo.net/api/rights/4/specific_platforms"/>
    <link rel="sourced_schedulings" href="https://movida.bebanjo.net/api/rights/4/sourced_schedulings"/>
    <link rel="note" href="https://movida.bebanjo.net/api/rights/4/note"/>
    <link rel="metadata" href="https://movida.bebanjo.net/api/rights/4/metadata"/>
  </right>
  <right>
    <id type="integer">5</id>
    <external-id nil="true"/>
    <name>Right #1</name>
    <right-type>archive</right-type>
    <starts type="datetime">2022-01-01T00:00:00Z</starts>
    <ends type="datetime">2023-01-01T00:00:00Z</ends>
    <clearances-included type="boolean">true</clearances-included>
    <minimum-exploitation nil="true"/>
    <maximum-exploitation nil="true"/>
    <exploitation-limits-context nil="true"/>
    <rerun-limit nil="true"/>
    <parity nil="true"/>
    <link rel="self" href="https://movida.bebanjo.net/api/rights/5"/>
    <link rel="deal" href="https://movida.bebanjo.net/api/deals/2"/>
    <link rel="licensable" href="https://movida.bebanjo.net/api/titles/2"/>
    <link rel="granted_requirements" href="https://movida.bebanjo.net/api/rights/5/granted_requirements"/>
    <link rel="specific_platforms" href="https://movida.bebanjo.net/api/rights/5/specific_platforms"/>
    <link rel="sourced_schedulings" href="https://movida.bebanjo.net/api/rights/5/sourced_schedulings"/>
    <link rel="note" href="https://movida.bebanjo.net/api/rights/5/note"/>
    <link rel="metadata" href="https://movida.bebanjo.net/api/rights/5/metadata"/>
  </right>
  <right>
    <id type="integer">6</id>
    <external-id nil="true"/>
    <name>Right #1</name>
    <right-type>archive</right-type>
    <starts type="datetime">2022-01-01T00:00:00Z</starts>
    <ends type="datetime">2023-01-01T00:00:00Z</ends>
    <clearances-included type="boolean">true</clearances-included>
    <minimum-exploitation nil="true"/>
    <maximum-exploitation nil="true"/>
    <exploitation-limits-context nil="true"/>
    <rerun-limit nil="true"/>
    <parity nil="true"/>
    <link rel="self" href="https://movida.bebanjo.net/api/rights/6"/>
    <link rel="deal" href="https://movida.bebanjo.net/api/deals/2"/>
    <link rel="licensable" href="https://movida.bebanjo.net/api/titles/3"/>
    <link rel="granted_requirements" href="https://movida.bebanjo.net/api/rights/6/granted_requirements"/>
    <link rel="specific_platforms" href="https://movida.bebanjo.net/api/rights/6/specific_platforms"/>
    <link rel="sourced_schedulings" href="https://movida.bebanjo.net/api/rights/6/sourced_schedulings"/>
    <link rel="note" href="https://movida.bebanjo.net/api/rights/6/note"/>
    <link rel="metadata" href="https://movida.bebanjo.net/api/rights/6/metadata"/>
  </right>
</rights>
{
  "total_entries": 3,
  "entries": [
    {
      "resource_type": "right",
      "id": 4,
      "external_id": null,
      "name": "Right #1",
      "right_type": "archive",
      "starts": "2022-01-01T00:00:00Z",
      "ends": "2023-01-01T00:00:00Z",
      "clearances_included": true,
      "minimum_exploitation": null,
      "maximum_exploitation": null,
      "exploitation_limits_context": null,
      "rerun_limit": null,
      "parity": null,
      "self_link": "https://movida.bebanjo.net/api/rights/4",
      "deal_link": "https://movida.bebanjo.net/api/deals/2",
      "licensable_link": "https://movida.bebanjo.net/api/titles/1",
      "granted_requirements_link": "https://movida.bebanjo.net/api/rights/4/granted_requirements",
      "specific_platforms_link": "https://movida.bebanjo.net/api/rights/4/specific_platforms",
      "sourced_schedulings_link": "https://movida.bebanjo.net/api/rights/4/sourced_schedulings",
      "note_link": "https://movida.bebanjo.net/api/rights/4/note",
      "metadata_link": "https://movida.bebanjo.net/api/rights/4/metadata"
    },
    {
      "resource_type": "right",
      "id": 5,
      "external_id": null,
      "name": "Right #1",
      "right_type": "archive",
      "starts": "2022-01-01T00:00:00Z",
      "ends": "2023-01-01T00:00:00Z",
      "clearances_included": true,
      "minimum_exploitation": null,
      "maximum_exploitation": null,
      "exploitation_limits_context": null,
      "rerun_limit": null,
      "parity": null,
      "self_link": "https://movida.bebanjo.net/api/rights/5",
      "deal_link": "https://movida.bebanjo.net/api/deals/2",
      "licensable_link": "https://movida.bebanjo.net/api/titles/2",
      "granted_requirements_link": "https://movida.bebanjo.net/api/rights/5/granted_requirements",
      "specific_platforms_link": "https://movida.bebanjo.net/api/rights/5/specific_platforms",
      "sourced_schedulings_link": "https://movida.bebanjo.net/api/rights/5/sourced_schedulings",
      "note_link": "https://movida.bebanjo.net/api/rights/5/note",
      "metadata_link": "https://movida.bebanjo.net/api/rights/5/metadata"
    },
    {
      "resource_type": "right",
      "id": 6,
      "external_id": null,
      "name": "Right #1",
      "right_type": "archive",
      "starts": "2022-01-01T00:00:00Z",
      "ends": "2023-01-01T00:00:00Z",
      "clearances_included": true,
      "minimum_exploitation": null,
      "maximum_exploitation": null,
      "exploitation_limits_context": null,
      "rerun_limit": null,
      "parity": null,
      "self_link": "https://movida.bebanjo.net/api/rights/6",
      "deal_link": "https://movida.bebanjo.net/api/deals/2",
      "licensable_link": "https://movida.bebanjo.net/api/titles/3",
      "granted_requirements_link": "https://movida.bebanjo.net/api/rights/6/granted_requirements",
      "specific_platforms_link": "https://movida.bebanjo.net/api/rights/6/specific_platforms",
      "sourced_schedulings_link": "https://movida.bebanjo.net/api/rights/6/sourced_schedulings",
      "note_link": "https://movida.bebanjo.net/api/rights/6/note",
      "metadata_link": "https://movida.bebanjo.net/api/rights/6/metadata"
    }
  ]
}

Get a list of rights from a feature or series

Given an existing feature, for example:

<title>
  <id type="integer">12</id>
  <name>Silicon Computers</name>
  <title>Silicon Computers</title>
  <external-id nil="true"/>
  <title-type>feature</title-type>
  <tags></tags>
  <link rel="self" href="https://movida.bebanjo.net/api/titles/12"/>
  <link rel="schedule" href="https://movida.bebanjo.net/api/titles/12/schedule"/>
  <link rel="availability_windows" href="https://movida.bebanjo.net/api/titles/12/availability_windows"/>
  <link rel="title_groups" href="https://movida.bebanjo.net/api/titles/12/title_groups"/>
  <link rel="licensor" href="https://movida.bebanjo.net/api/licensors/114"/>
  <link rel="images" href="https://movida.bebanjo.net/api/titles/12/images"/>
  <link rel="assets" href="https://movida.bebanjo.net/api/titles/12/assets"/>
  <link rel="metadata" href="https://movida.bebanjo.net/api/titles/12/metadata"/>
  <link rel="blackouts" href="https://movida.bebanjo.net/api/titles/12/blackouts"/>
  <link rel="rights" href="https://movida.bebanjo.net/api/titles/12/rights"/>
  <link rel="denied_rights" href="https://movida.bebanjo.net/api/titles/12/denied_rights"/>
  <link rel="trailers" href="https://movida.bebanjo.net/api/titles/12/trailers"/>
</title>
{
  "resource_type": "title",
  "id": 12,
  "name": "Silicon Computers",
  "title": "Silicon Computers",
  "external_id": null,
  "title_type": "feature",
  "tags": "",
  "self_link": "https://movida.bebanjo.net/api/titles/12",
  "schedule_link": "https://movida.bebanjo.net/api/titles/12/schedule",
  "linear_schedulings_link": "https://movida.bebanjo.net/api/titles/12/linear_schedulings",
  "availability_windows_link": "https://movida.bebanjo.net/api/titles/12/availability_windows",
  "title_groups_link": "https://movida.bebanjo.net/api/titles/12/title_groups",
  "licensor_link": "https://movida.bebanjo.net/api/licensors/114",
  "images_link": "https://movida.bebanjo.net/api/titles/12/images",
  "assets_link": "https://movida.bebanjo.net/api/titles/12/assets",
  "metadata_link": "https://movida.bebanjo.net/api/titles/12/metadata",
  "blackouts_link": "https://movida.bebanjo.net/api/titles/12/blackouts",
  "rights_link": "https://movida.bebanjo.net/api/titles/12/rights",
  "denied_rights_link": "https://movida.bebanjo.net/api/titles/12/denied_rights",
  "rules_link": "https://movida.bebanjo.net/api/titles/12/rules",
  "clips_link": "https://movida.bebanjo.net/api/titles/12/clips",
  "note_link": "https://movida.bebanjo.net/api/titles/12/note"
}

All the rights of that feature can be obtained by following the link rel="rights":

$ curl --digest -u robot_user:password https://movida.bebanjo.net/api/titles/12/rights
$ curl --digest -u robot_user:password -H "Accept: application/json" https://movida.bebanjo.net/api/titles/12/rights
<?xml version="1.0" encoding="UTF-8"?>
<rights type="array">
  <total-entries>2</total-entries>
  <right>
    <id type="integer">7</id>
    <external-id>FR2</external-id>
    <name>Right #1</name>
    <right-type>archive</right-type>
    <starts type="datetime">2013-10-10T00:00:00Z</starts>
    <ends type="datetime">2014-10-10T00:00:00Z</ends>
    <clearances-included type="boolean">true</clearances-included>
    <minimum-exploitation nil="true"/>
    <maximum-exploitation nil="true"/>
    <exploitation-limits-context nil="true"/>
    <rerun-limit nil="true"/>
    <parity nil="true"/>
    <link rel="self" href="https://movida.bebanjo.net/api/rights/7"/>
    <link rel="licensable" href="https://movida.bebanjo.net/api/titles/12"/>
    <link rel="granted_requirements" href="https://movida.bebanjo.net/api/rights/7/granted_requirements"/>
    <link rel="specific_platforms" href="https://movida.bebanjo.net/api/rights/7/specific_platforms"/>
    <link rel="sourced_schedulings" href="https://movida.bebanjo.net/api/rights/7/sourced_schedulings"/>
    <link rel="note" href="https://movida.bebanjo.net/api/rights/7/note"/>
    <link rel="metadata" href="https://movida.bebanjo.net/api/rights/7/metadata"/>
  </right>
  <right>
    <id type="integer">8</id>
    <external-id nil="true"/>
    <name>Right #2</name>
    <right-type>archive</right-type>
    <starts type="datetime">2022-01-01T00:00:00Z</starts>
    <ends type="datetime">2023-01-01T00:00:00Z</ends>
    <clearances-included type="boolean">true</clearances-included>
    <minimum-exploitation nil="true"/>
    <maximum-exploitation nil="true"/>
    <exploitation-limits-context nil="true"/>
    <rerun-limit nil="true"/>
    <parity nil="true"/>
    <link rel="self" href="https://movida.bebanjo.net/api/rights/8"/>
    <link rel="licensable" href="https://movida.bebanjo.net/api/titles/12"/>
    <link rel="granted_requirements" href="https://movida.bebanjo.net/api/rights/8/granted_requirements"/>
    <link rel="specific_platforms" href="https://movida.bebanjo.net/api/rights/8/specific_platforms"/>
    <link rel="sourced_schedulings" href="https://movida.bebanjo.net/api/rights/8/sourced_schedulings"/>
    <link rel="note" href="https://movida.bebanjo.net/api/rights/8/note"/>
    <link rel="metadata" href="https://movida.bebanjo.net/api/rights/8/metadata"/>
  </right>
</rights>
{
  "total_entries": 2,
  "entries": [
    {
      "resource_type": "right",
      "id": 7,
      "external_id": "FR2",
      "name": "Right #1",
      "right_type": "archive",
      "starts": "2013-10-10T00:00:00Z",
      "ends": "2014-10-10T00:00:00Z",
      "clearances_included": true,
      "minimum_exploitation": null,
      "maximum_exploitation": null,
      "exploitation_limits_context": null,
      "rerun_limit": null,
      "parity": null,
      "self_link": "https://movida.bebanjo.net/api/rights/7",
      "licensable_link": "https://movida.bebanjo.net/api/titles/12",
      "granted_requirements_link": "https://movida.bebanjo.net/api/rights/7/granted_requirements",
      "specific_platforms_link": "https://movida.bebanjo.net/api/rights/7/specific_platforms",
      "sourced_schedulings_link": "https://movida.bebanjo.net/api/rights/7/sourced_schedulings",
      "note_link": "https://movida.bebanjo.net/api/rights/7/note",
      "metadata_link": "https://movida.bebanjo.net/api/rights/7/metadata"
    },
    {
      "resource_type": "right",
      "id": 8,
      "external_id": null,
      "name": "Right #2",
      "right_type": "archive",
      "starts": "2022-01-01T00:00:00Z",
      "ends": "2023-01-01T00:00:00Z",
      "clearances_included": true,
      "minimum_exploitation": null,
      "maximum_exploitation": null,
      "exploitation_limits_context": null,
      "rerun_limit": null,
      "parity": null,
      "self_link": "https://movida.bebanjo.net/api/rights/8",
      "licensable_link": "https://movida.bebanjo.net/api/titles/12",
      "granted_requirements_link": "https://movida.bebanjo.net/api/rights/8/granted_requirements",
      "specific_platforms_link": "https://movida.bebanjo.net/api/rights/8/specific_platforms",
      "sourced_schedulings_link": "https://movida.bebanjo.net/api/rights/8/sourced_schedulings",
      "note_link": "https://movida.bebanjo.net/api/rights/8/note",
      "metadata_link": "https://movida.bebanjo.net/api/rights/8/metadata"
    }
  ]
}

Get a single right

Just do a GET to the URI of the right (the one in the attribute rel="self"):

$ curl --digest -u robot_user:password https://movida.bebanjo.net/rights/6
$ curl --digest -u robot_user:password -H "Accept: application/json" https://movida.bebanjo.net/rights/6
<right>
  <id type="integer">6</id>
  <external-id>RR12-5</external-id>
  <name>Right #5</name>
  <right-type>archive</right-type>
  <starts type="datetime">2013-01-10T00:00:00Z</starts>
  <ends type="datetime">2015-01-10T00:00:00Z</ends>
  <clearances-included type="boolean">true</clearances-included>
  <utility-limit type="integer">3</utility-limit>
  <repeats type="boolean">false</repeats>
  <minimum-exploitation nil="true"/>
  <maximum-exploitation nil="true"/>
  <exploitation-limits-context nil="true"/>
  <rerun-limit nil="true"/>
  <parity nil="true"/>
  <link rel="self" href="https://movida.bebanjo.net/rights/6"/>
  <link rel="licensable" href="https://movida.bebanjo.net/titles/3"/>
  <link rel="licensor" href="https://movida.bebanjo.net/api/licensors/114"/>
  <link rel="granted_requirements" href="https://movida.bebanjo.net/rights/6/granted_requirements"/>
  <link rel="specific_platforms" href="https://movida.bebanjo.net/rights/6/specific_platforms"/>
  <link rel="sourced_schedulings" href="https://movida.bebanjo.net/api/rights/6/sourced_schedulings"/>
  <link rel="note" href="https://movida.bebanjo.net/api/rights/6/note"/>
  <link rel="metadata" href="https://movida.bebanjo.net/api/rights/6/metadata"/>
</right>
{
  "resource_type": "right",
  "id": 6,
  "external_id": "RR12-5",
  "name": "Right #5",
  "right_type": "archive",
  "starts": "2013-01-10T00:00:00Z",
  "ends": "2015-01-10T00:00:00Z",
  "clearances_included": true,
  "minimum_exploitation": null,
  "maximum_exploitation": null,
  "exploitation_limits_context": null,
  "rerun_limit": null,
  "parity": null,
  "self_link": "https://movida.bebanjo.net/api/rights/6",
  "licensable_link": "https://movida.bebanjo.net/api/titles/3",
  "licensor_link": "https://movida.bebanjo.net/api/licensors/114",
  "granted_requirements_link": "https://movida.bebanjo.net/api/rights/6/granted_requirements",
  "specific_platforms_link": "https://movida.bebanjo.net/api/rights/6/specific_platforms",
  "sourced_schedulings_link": "https://movida.bebanjo.net/api/rights/6/sourced_schedulings",
  "note_link": "https://movida.bebanjo.net/api/rights/6/note",
  "metadata_link": "https://movida.bebanjo.net/api/rights/6/metadata"
}

Creating rights for a deal (or a licensable)

To create a right, you just need to POST a proper XML/JSON right representation (similar to the ones you get when fetching a deal or a licensable) to the rights URL of a given deal or licensable. As explained above, that URL is in the link node whose rel attribute equals rights.

For example, the following XML/JSON issued as a POST to the rights URL of a deal would create a right (we’ll use $ curl’s @ option, which reads data to be posted from a file):

$ cat right.xml
$ cat right.json
<right>
  <external-id>RR12-99</external-id>
  <right-type>archive</right-type>
  <starts type="datetime">2010-10-10</starts>
  <ends type="datetime">2011-10-10</ends>
  <episode-selection-type>except</episode-selection-type>
  <episode-selection>1,3</episode-selection>
  <link rel="licensable" href="https://movida.bebanjo.net/api/title_groups/1"/>
  <link rel="licensor" href="https://movida.bebanjo.net/api/licensors/115"/>
</right>
{
  "external_id": "RR12-99",
  "right_type": "archive",
  "starts": "2010-10-10",
  "ends": "2011-10-10",
  "episode_selection_type": "except",
  "episode_selection": "1,3",
  "licensable_link": "https://movida.bebanjo.net/api/title_groups/1",
  "licensor_link": "https://movida.bebanjo.net/api/licensors/115"
}

Note: The licensor URL must be of one licensor that already exists in the system, otherwise you will receive a message error reporting the licensor doesn’t exist. See how to create licensors in the licensor page.

$ curl --digest -u robot_user:password -H "Content-Type: application/xml" -X POST -d @right.xml "https://movida.bebanjo.net/api/deals/9/rights"
$ curl --digest -u robot_user:password -H "Content-Type: application/json" -H "Accept: application/json" -X POST -d @right.json "https://movida.bebanjo.net/api/deals/9/rights"

BeBanjo will return the full XML/JSON of the right just created:

<?xml version="1.0" encoding="UTF-8"?>
<right>
  <id type="integer">13</id>
  <external-id>RR12-99</external-id>
  <name>Right #1</name>
  <right-type>archive</right-type>
  <starts type="datetime">2010-10-10T00:00:00Z</starts>
  <ends type="datetime">2011-10-10T00:00:00Z</ends>
  <episode-selection-type>except</episode-selection-type>
  <episode-selection>1,3</episode-selection>
  <clearances-included type="boolean">true</clearances-included>
  <utility-limit nil="true"/>
  <repeats type="boolean">false</repeats>
  <minimum-exploitation nil="true"/>
  <maximum-exploitation nil="true"/>
  <exploitation-limits-context nil="true"/>
  <rerun-limit nil="true"/>
  <parity nil="true"/>
  <link rel="self" href="https://movida.bebanjo.net/api/rights/13"/>
  <link rel="deal" href="https://movida.bebanjo.net/deals/9"/>
  <link rel="licensable" href="https://movida.bebanjo.net/title_groups/1"/>
  <link rel="licensor" href="https://movida.bebanjo.net/api/licensors/115"/>
  <link rel="granted_requirements" href="https://movida.bebanjo.net/rights/13/granted_requirements"/>
  <link rel="specific_platforms" href="https://movida.bebanjo.net/rights/13/specific_platforms"/>
  <link rel="sourced_schedulings" href="https://movida.bebanjo.net/api/rights/13/sourced_schedulings"/>
  <link rel="note" href="https://movida.bebanjo.net/api/rights/13/note"/>
  <link rel="metadata" href="https://movida.bebanjo.net/api/rights/13/metadata"/>
</right>
{
  "resource_type": "right",
  "id": 13,
  "external_id": "RR12-99",
  "name": "Right #1",
  "right_type": "archive",
  "starts": "2010-10-10T00:00:00Z",
  "ends": "2011-10-10T00:00:00Z",
  "episode_selection_type": "except",
  "episode_selection": "1,3",
  "clearances_included": true,
  "utility_limit": null,
  "repeats": false,
  "minimum_exploitation": null,
  "maximum_exploitation": null,
  "exploitation_limits_context": null,
  "rerun_limit": null,
  "parity": null,
  "self_link": "https://movida.bebanjo.net/api/rights/13",
  "deal_link": "https://movida.bebanjo.net/api/deals/9",
  "licensable_link": "https://movida.bebanjo.net/api/title_groups/1",
  "licensor_link": "https://movida.bebanjo.net/api/licensors/115",
  "granted_requirements_link": "https://movida.bebanjo.net/api/rights/13/granted_requirements",
  "specific_platforms_link": "https://movida.bebanjo.net/api/rights/13/specific_platforms",
  "sourced_schedulings_link": "https://movida.bebanjo.net/api/rights/13/sourced_schedulings",
  "note_link": "https://movida.bebanjo.net/api/rights/13/note",
  "metadata_link": "https://movida.bebanjo.net/api/rights/13/metadata"
}

A right for a feature or a series can be created the same way, issuing a POST request to that feature or series rights URL.

To create granted_requirements for a right refer to the granted requirement

Inheriting attributes from the deal

The only mandatory attribute is the licensable, any other attribute, that is not present at the xml/json, will get a value inherited from the corresponding Deal attribute. The only attributes that will not be inherited from the Deal are: id, external-id, name and clearances-included.

If you have the following deal:

<deal>
  <id type="integer">123</id>
  <name>Marvel Deal 2013</name>
  <external-id>Marvel2013</external-id>
  <right-type>archive</right-type>
  <starts type="datetime">2014-10-10T00:00:00Z</starts>
  <ends type="datetime">2015-10-31T00:00:00Z</ends>
  <rights-updated-at type="datetime">2014-10-01T00:00:00Z</rights-updated-at>
  <utility-limit type="integer">3</utility-limit>
  <repeats type="boolean">false</repeats>
  <minimum-exploitation>1</minimum-exploitation>
  <maximum-exploitation>10</maximum-exploitation>
  <exploitation-limits-context>total</exploitation-limits-context>
  <rerun-limit nil="true"/>
  <parity>start+end</parity>
  <link rel="self" href="https://movida.bebanjo.net/api/deals/123"/>
  <link rel="rights" href="https://movida.bebanjo.net/api/deals/123/rights"/>
  <link rel="metadata" href="https://movida.bebanjo.net/api/deals/123/metadata"/>
  <link rel="licensor" href="https://movida.bebanjo.net/api/licensors/114"/>
  <link rel="granted_requirements" href="https://movida.bebanjo.net/api/deals/123/granted_requirements"/>
  <link rel="specific_platforms" href="https://movida.bebanjo.net/api/deals/123/specific_platforms"/>
</deal>
{
  "resource_type": "deal",
  "id": 123,
  "name": "Marvel Deal 2013",
  "external_id": "Marvel2013",
  "right_type": "archive",
  "starts": "2014-10-10T00:00:00Z",
  "ends": "2015-10-31T00:00:00Z",
  "rights_updated_at": "2014-10-01T00:00:00Z",
  "utility_limit": 3,
  "repeats": false,
  "minimum_exploitation": 1,
  "maximum_exploitation": 10,
  "exploitation_limits_context": "total",
  "rerun_limit": null,
  "parity": "start+end",
  "self_link": "https://movida.bebanjo.net/api/deals/123",
  "rights_link": "https://movida.bebanjo.net/api/deals/123/rights",
  "metadata_link": "https://movida.bebanjo.net/api/deals/123/metadata",
  "licensor_link": "https://movida.bebanjo.net/api/licensors/114",
  "granted_requirements_link": "https://movida.bebanjo.net/api/deals/123/granted_requirements",
  "specific_platforms_link": "https://movida.bebanjo.net/api/deals/123/specific_platforms"
}

And you create the following right:

$ cat right.xml
$ cat right.json
<right>
  <external-id>RR12-5</external-id>
  <name>Right RR12#5</name>
  <utility-limit nil="true"/>
  <episode-selection-type>except</episode-selection-type>
  <episode-selection>1,3</episode-selection>
  <link rel="licensable" href="https://movida.bebanjo.net/title_groups/2"/>
</right>
{
  "external_id": "RR12-5",
  "name": "Right RR12#5",
  "utility_limit": "",
  "episode_selection_type": "except",
  "episode_selection": "1,3",
  "licensable_link": "https://movida.bebanjo.net/title_groups/2"
}
$ curl --digest -u robot_user:password -H "Content-Type: application/xml" -X POST -d @right.xml "https://movida.bebanjo.net/api/deals/123/rights"
$ curl --digest -u robot_user:password -H "Content-Type: application/json" -H "Accept: application/json" -X POST -d @right.json "https://movida.bebanjo.net/api/deals/123/rights"

You’ll get the following right:

<?xml version="1.0" encoding="UTF-8"?>
<right>
  <id type="integer">15</id>
  <external-id>RR12-5</external-id>
  <name>Right RR12#5</name>
  <right-type>archive</right-type>
  <starts type="datetime">2014-10-10T00:00:00Z</starts>
  <ends type="datetime">2015-10-31T00:00:00Z</ends>
  <episode-selection-type>except</episode-selection-type>
  <episode-selection>1,3</episode-selection>
  <clearances-included type="boolean">true</clearances-included>
  <utility-limit nil="true"/>
  <repeats type="boolean">false</repeats>
  <minimum-exploitation>1</minimum-exploitation>
  <maximum-exploitation>10</maximum-exploitation>
  <exploitation-limits-context>total</exploitation-limits-context>
  <rerun-limit nil="true"/>
  <parity>start+end</parity>
  <link rel="self" href="https://movida.bebanjo.net/api/rights/15"/>
  <link rel="deal" href="https://movida.bebanjo.net/deals/123"/>
  <link rel="licensable" href="https://movida.bebanjo.net/title_groups/2"/>
  <link rel="licensor" href="https://movida.bebanjo.net/api/licensors/114"/>
  <link rel="granted_requirements" href="https://movida.bebanjo.net/rights/15/granted_requirements"/>
  <link rel="specific_platforms" href="https://movida.bebanjo.net/rights/15/specific_platforms"/>
  <link rel="sourced_schedulings" href="https://movida.bebanjo.net/api/rights/15/sourced_schedulings"/>
  <link rel="note" href="https://movida.bebanjo.net/api/rights/15/note"/>
  <link rel="metadata" href="https://movida.bebanjo.net/api/rights/15/metadata"/>
</right>
{
  "resource_type": "right",
  "id": 15,
  "external_id": "RR12-5",
  "name": "Right RR12#5",
  "right_type": "archive",
  "starts": "2014-10-10T00:00:00Z",
  "ends": "2015-10-31T00:00:00Z",
  "episode_selection_type": "except",
  "episode_selection": "1,3",
  "clearances_included": true,
  "utility_limit": null,
  "repeats": false,
  "minimum_exploitation": null,
  "maximum_exploitation": null,
  "exploitation_limits_context": null,
  "rerun_limit": null,
  "parity": null,
  "self_link": "https://movida.bebanjo.net/api/rights/15",
  "deal_link": "https://movida.bebanjo.net/api/deals/123",
  "licensable_link": "https://movida.bebanjo.net/api/title_groups/2",
  "licensor_link": "https://movida.bebanjo.net/api/licensors/114",
  "granted_requirements_link": "https://movida.bebanjo.net/api/rights/15/granted_requirements",
  "specific_platforms_link": "https://movida.bebanjo.net/api/rights/15/specific_platforms",
  "sourced_schedulings_link": "https://movida.bebanjo.net/api/rights/15/sourced_schedulings",
  "note_link": "https://movida.bebanjo.net/api/rights/15/note",
  "metadata_link": "https://movida.bebanjo.net/api/rights/15/metadata"
}

As you see utility-limit value is not inherited from the Deal, as the xml/json included it with an empty value. Besides the right is created with the same granted_requirements and specific_platforms than the Deal. These resources cannot be modified when the right is linked to a deal.

Updating a right

As our introduction to REST APIs page suggests, you can update a right issuing a PUT request to each right URI:

$ cat right_update.xml
$ cat right_update.json
<right>
  <episode-selection-type>only</episode-selection-type>
  <episode-selection>1,2</episode-selection>
  <link rel="licensor" href="https://movida.bebanjo.net/api/licensors/115"/>
</right>
{
  "episode_selection_type": "only",
  "episode_selection": "1,2",
  "licensor_link": "https://movida.bebanjo.net/api/licensors/115"
}

Note: The licensor URL must be of one licensor that already exists in the system, otherwise you will receive a message error reporting the licensor doesn’t exist. See how to create licensors in the licensor page.

$ curl --digest -u robot_user:password -H "Content-Type: application/xml" -X PUT -d @right_update.xml "https://movida.bebanjo.net/api/rights/13"
$ curl --digest -u robot_user:password -H "Content-Type: application/json" -H "Accept: application/json" -X PUT -d @right_update.json "https://movida.bebanjo.net/api/rights/13"

As always BeBanjo will return the full XML/JSON of the right just updated:

<?xml version="1.0" encoding="UTF-8"?>
<right>
  <id type="integer">13</id>
  <external-id>RR12-4</external-id>
  <name>Right RR12#4</name>
  <right-type>archive</right-type>
  <starts type="datetime">2010-10-10T00:00:00Z</starts>
  <ends type="datetime">2011-10-10T00:00:00Z</ends>
  <episode-selection-type>only</episode-selection-type>
  <episode-selection>1,2</episode-selection>
  <clearances-included type="boolean">true</clearances-included>
  <utility-limit nil="true"/>
  <repeats type="boolean">false</repeats>
  <minimum-exploitation>1</minimum-exploitation>
  <maximum-exploitation>10</maximum-exploitation>
  <exploitation-limits-context>total</exploitation-limits-context>
  <rerun-limit nil="true"/>
  <parity>start+end</parity>
  <link rel="self" href="https://movida.bebanjo.net/api/rights/13"/>
  <link rel="deal" href="https://movida.bebanjo.net/api/deals/123"/>
  <link rel="licensable" href="https://movida.bebanjo.net/api/title_groups/2"/>
  <link rel="licensor" href="https://movida.bebanjo.net/api/licensors/115"/>
  <link rel="granted_requirements" href="https://movida.bebanjo.net/api/rights/13/granted_requirements"/>
  <link rel="specific_platforms" href="https://movida.bebanjo.net/api/rights/13/specific_platforms"/>
  <link rel="sourced_schedulings" href="https://movida.bebanjo.net/api/rights/4/sourced_schedulings"/>
  <link rel="note" href="https://movida.bebanjo.net/api/rights/4/note"/>
  <link rel="metadata" href="https://movida.bebanjo.net/api/rights/4/metadata"/>
</right>
{
  "resource_type": "right",
  "id": 13,
  "external_id": "RR12-4",
  "name": "Right RR12#4",
  "right_type": "archive",
  "starts": "2010-10-10T00:00:00Z",
  "ends": "2011-10-10T00:00:00Z",
  "episode_selection_type": "only",
  "episode_selection": "1,2",
  "clearances_included": true,
  "utility_limit": 3,
  "repeats": false,
  "minimum_exploitation": 1,
  "maximum_exploitation": 10,
  "exploitation_limits_context": "total",
  "rerun_limit": null,
  "parity": null,
  "self_link": "https://movida.bebanjo.net/api/rights/13",
  "deal_link": "https://movida.bebanjo.net/api/deals/123",
  "licensable_link": "https://movida.bebanjo.net/api/title_groups/2",
  "licensor_link": "https://movida.bebanjo.net/api/licensors/115",
  "granted_requirements_link": "https://movida.bebanjo.net/api/rights/13/granted_requirements",
  "specific_platforms_link": "https://movida.bebanjo.net/api/rights/13/specific_platforms",
  "sourced_schedulings_link": "https://movida.bebanjo.net/api/rights/13/sourced_schedulings",
  "note_link": "https://movida.bebanjo.net/api/rights/13/note",
  "metadata_link": "https://movida.bebanjo.net/api/rights/13/metadata"
}

Deleting a right

Also you can delete a right using DELETE request to each right URI:

$ curl --digest -u robot_user:password -X DELETE "https://movida.bebanjo.net/api/rights/13"
$ curl --digest -u robot_user:password -H "Accept: application/json" -X DELETE "https://movida.bebanjo.net/api/rights/13"

The DELETE request doesn’t return anything, as that right is now gone.