Schedule Information API

Command: holiday

Inputs

Parameter Description
cmd=holiday Requests information about the upcoming BART holidays, and what schedule will be run on those days. (Required)
key=<key> API registration key. (Required)
json=y Returns API output in JSON format. Default output is XML if parameter not specified. (Optional)

Notes

On BART Holidays, the trains may run on a different schedule from normal. This typically will mean that a Sunday/Holiday schedule will be used, however, sometimes a Saturday schedule is used. The Schedule Information API will automatically use the appropriate schedule for any trip that coincides with a BART holiday. In addition, a message will be appended to the trip results stating that a holiday schedule was used.

Results

XML Sample

<?xml version="1.0" encoding="utf-8"?>
<root>
  <uri>
    <![CDATA[http://api.bart.gov/api/sched.aspx?cmd=holiday]]>
  </uri>
  <holidays>
    <holiday>
      <name>Thanksgiving Day</name>
      <date>11/24/2016</date>
      <schedule_type>Sunday</schedule_type>
    </holiday>
    <holiday>
      <name>Christmas Day</name>
      <date>12/25/2016</date>
      <schedule_type>Sunday</schedule_type>
    </holiday>
    <holiday>
      <name>New Year's Day</name>
      <date>01/01/2017</date>
      <schedule_type>Sunday</schedule_type>
    </holiday>
    <holiday>
      <name>Martin Luther King, Jr. Day</name>
      <date>01/16/2017</date>
      <schedule_type>Saturday</schedule_type>
    </holiday>
    <holiday>
      <name>Presidents' Day</name>
      <date>02/20/2017</date>
      <schedule_type>Saturday</schedule_type>
    </holiday>
    <holiday>
      <name>Memorial Day</name>
      <date>05/29/2017</date>
      <schedule_type>Sunday</schedule_type>
    </holiday>
    <holiday>
      <name>Independence Day</name>
      <date>07/04/2017</date>
      <schedule_type>Sunday</schedule_type>
    </holiday>
    <holiday>
      <name>Labor Day</name>
      <date>09/04/2017</date>
      <schedule_type>Sunday</schedule_type>
    </holiday>
    <holiday>
      <name>Thanksgiving Day</name>
      <date>11/23/2017</date>
      <schedule_type>Sunday</schedule_type>
    </holiday>
    <holiday>
      <name>Christmas Day</name>
      <date>12/25/2017</date>
      <schedule_type>Sunday</schedule_type>
    </holiday>
    <holiday>
      <name>New Year's Day</name>
      <date>01/01/2018</date>
      <schedule_type>Sunday</schedule_type>
    </holiday>
  </holidays>
  <message></message>
</root>

JSON Sample

{
   "?xml":{
      "@version":"1.0",
      "@encoding":"utf-8"
   },
   "root":{
      "@id":"1",
      "uri":{
         "#cdata-section":"http://api.bart.gov/api/sched.aspx?cmd=holiday&json=y"
      },
      "holidays":[
         {
            "holiday":[
               {
                  "name":"Thanksgiving Day",
                  "date":"11/24/2016",
                  "schedule_type":"Sunday"
               },
               {
                  "name":"Christmas Day",
                  "date":"12/25/2016",
                  "schedule_type":"Sunday"
               },
               {
                  "name":"New Year's Day",
                  "date":"01/01/2017",
                  "schedule_type":"Sunday"
               },
               {
                  "name":"Martin Luther King, Jr. Day",
                  "date":"01/16/2017",
                  "schedule_type":"Saturday"
               },
               {
                  "name":"Presidents' Day",
                  "date":"02/20/2017",
                  "schedule_type":"Saturday"
               },
               {
                  "name":"Memorial Day",
                  "date":"05/29/2017",
                  "schedule_type":"Sunday"
               },
               {
                  "name":"Independence Day",
                  "date":"07/04/2017",
                  "schedule_type":"Sunday"
               },
               {
                  "name":"Labor Day",
                  "date":"09/04/2017",
                  "schedule_type":"Sunday"
               },
               {
                  "name":"Thanksgiving Day",
                  "date":"11/23/2017",
                  "schedule_type":"Sunday"
               },
               {
                  "name":"Christmas Day",
                  "date":"12/25/2017",
                  "schedule_type":"Sunday"
               },
               {
                  "name":"New Year's Day",
                  "date":"01/01/2018",
                  "schedule_type":"Sunday"
               }
            ]
         }
      ],
      "message":""
   }
}

Notes

None.

Usage

XML: http://api.bart.gov/api/sched.aspx?cmd=holiday&key=MW9S-E7SL-26DU-VV8V
JSON: http://api.bart.gov/api/sched.aspx?cmd=holiday&key=MW9S-E7SL-26DU-VV8V&json=y