# obspy.clients.fdsn.client.Client.get_waveforms_bulk

`Client.``get_waveforms_bulk`(bulk, quality=None, minimumlength=None, longestonly=None, filename=None, attach_response=False, **kwargs)

  Query the dataselect service of the client. Bulk request.

  Send a bulk request for waveforms to the server. bulk can either be specified as a filename, a file-like object or a string (with information formatted according to the FDSN standard) or a list of lists (each specifying network, station, location, channel, starttime and endtime). See examples and parameter description for more details.

  bulk can be provided in the following forms:

  1. As a list of lists. Each list item has to be list of network, station, location, channel, starttime and endtime.
  2. As a valid request string/file as defined in the FDSNWS documentation. The request information can be provided as a..
     - a string containing the request information
     - a string with the path to a local file with the request
     - an open file handle (or file-like object) with the request

      >>> client = Client("IRIS")
      >>> t1 = UTCDateTime("2010-02-27T06:30:00.000")
      >>> t2 = t1 + 1
      >>> t3 = t1 + 3
      >>> bulk = [("IU", "ANMO", "*", "BHZ", t1, t2),
      ...         ("IU", "AFI", "1?", "BHE", t1, t3),
      ...         ("GR", "GRA1", "*", "BH*", t2, t3)]
      >>> st = client.get_waveforms_bulk(bulk)
      >>> print(st)
      5 Trace(s) in Stream:
      GR.GRA1..BHE   | 2010-02-27T06:30:01... | 20.0 Hz, 40 samples
      GR.GRA1..BHN   | 2010-02-27T06:30:01... | 20.0 Hz, 40 samples
      GR.GRA1..BHZ   | 2010-02-27T06:30:01... | 20.0 Hz, 40 samples
      IU.ANMO.00.BHZ | 2010-02-27T06:30:00... | 20.0 Hz, 20 samples
      IU.ANMO.10.BHZ | 2010-02-27T06:30:00... | 40.0 Hz, 40 samples
      >>> bulk = 'quality=B\n' + \
      ...        'longestonly=false\n' + \
      ...        'IU ANMO * BHZ 2010-02-27 2010-02-27T00:00:02\n' + \
      ...        'IU AFI 1? BHE 2010-02-27 2010-02-27T00:00:04\n' + \
      ...        'GR GRA1 * BH? 2010-02-27 2010-02-27T00:00:02\n'
      >>> st = client.get_waveforms_bulk(bulk)
      >>> print(st)
      5 Trace(s) in Stream:
      GR.GRA1..BHE   | 2010-02-27T00:00:00... | 20.0 Hz, 40 samples
      GR.GRA1..BHN   | 2010-02-27T00:00:00... | 20.0 Hz, 40 samples
      GR.GRA1..BHZ   | 2010-02-27T00:00:00... | 20.0 Hz, 40 samples
      IU.ANMO.00.BHZ | 2010-02-27T00:00:00... | 20.0 Hz, 40 samples
      IU.ANMO.10.BHZ | 2010-02-27T00:00:00... | 40.0 Hz, 80 samples
      >>> st = client.get_waveforms_bulk("/tmp/request.txt") \
      ...
      >>> print(st)
      5 Trace(s) in Stream:
      GR.GRA1..BHE   | 2010-02-27T00:00:00... | 20.0 Hz, 40 samples
      GR.GRA1..BHN   | 2010-02-27T00:00:00... | 20.0 Hz, 40 samples
      GR.GRA1..BHZ   | 2010-02-27T00:00:00... | 20.0 Hz, 40 samples
      IU.ANMO.00.BHZ | 2010-02-27T00:00:00... | 20.0 Hz, 40 samples
      IU.ANMO.10.BHZ | 2010-02-27T00:00:00... | 40.0 Hz, 80 samples
      >>> t = UTCDateTime("2012-12-14T10:36:01.6Z")
      >>> t1 = t + 300
      >>> t2 = t + 400
      >>> bulk = [("TA", "S42A", "*", "BHZ", t1, t2),
      ...         ("TA", "W42A", "*", "BHZ", t1, t2),
      ...         ("TA", "Z42A", "*", "BHZ", t1, t2)]
      >>> st = client.get_waveforms_bulk(bulk, attach_response=True)
      >>> st.remove_response(output="VEL")
      <obspy.core.stream.Stream object at ...>
      >>> st.plot()

  (Source code, png, hires.png)

  Note

  Use attach_response=True to automatically add response information to each trace. This can be used to remove response using `remove_response()`.

  Parameters: | bulk (str, file or list of lists) Information about the requested data. See above for details. quality (str, optional) Select a specific SEED quality indicator, handling is data center dependent. Ignored when bulk is provided as a request string/file. minimumlength (float, optional) Limit results to continuous data segments of a minimum length specified in seconds. Ignored when bulk is provided as a request string/file. longestonly (bool, optional) Limit results to the longest continuous segment per channel. Ignored when bulk is provided as a request string/file. filename (str or file) If given, the downloaded data will be saved there instead of being parsed to an ObsPy object. Thus it will contain the raw data from the webservices. attach_response (bool) Specify whether the station web service should be used to automatically attach response information to each trace in the result set. A warning will be shown if a response can not be found for a channel. Does nothing if output to a file was specified.

  Any additional keyword arguments will be passed to the webservice as additional arguments. If you pass one of the default parameters and the webservice does not support it, a warning will be issued. Passing any non-default parameters that the webservice does not support will raise an error.

### Thank you!

We would like to thank our contributors, whose efforts make this software what it is. These people have helped by writing code and documentation, and by testing. They have created and maintained this product, its associated libraries and applications, our build tools and our web sites.

#### Contributors

- Ackerley, Nick
- Allgeyer, Sebastien
- Ammon, Charles J.
- Antunes, Emanuel
- Arnarsson, Ólafur St.
- Bank, Markus
- Barsch, Robert
- Behr, Yannik
- Bernardi, Fabrizio
- Bernauer, Felix
- Bes de Berc, Maxime
- Beyreuther, Moritz
- Boltz, Shawn
- Bonaimé, Sébastien
- Carothers, Lloyd
- Chamberlain, Calum
- Chambers, Derrick
- Chen, Zhao
- Clark, Adam
- Danecek, Peter
- Egdorf, Sven
- Engels, Fabian
- Ermert, Laura
- Eulenfeld, Tom

- Fabbri, Tommaso
- Falco, Nicholas
- Fee, Jeremy
- Grellier, Clément
- Grunberg, Marc
- Hammer, Conny
- Heimann, Sebastian
- Heiniger, Lukas
- Hope, Gaute
- Igel, Heiner
- Inza, Adolfo
- Isken, Marius
- Ketchum, David
- Koymans, Mathijs
- Kremers, Simon
- Kress, Victor
- Krieger, Lars
- Krischer, Lion
- Kula, Damian
- Käufl, Paul
- Köhler, Andreas
- Lecocq, Thomas
- Leeman, John
- Legovini, Paride

- Lesage, Philippe
- Li, Yulin
- Lomax, Anthony
- Lopes, Rui L.
- MacCarthy, Jonathan
- Maggi, Alessia
- Martin, Henri
- Medlin, Andrew
- Megies, Tobias
- Meschede, Matthias
- Michelini, Alberto
- Miller, Nathaniel C.
- Morgenstern, Bernhard
- Nof, Ran Novitsky
- Panning, Mark P.
- Parker, Tom
- Pestourie, Romain
- Rapagnani, Giovanni
- Reyes, Celso
- Ringler, Adam
- Rothenhäusler, Nicolas
- Russo, Emiliano
- Sales de Andrade, Elliott

- Satriano, Claudio
- Saul, Joachim
- Scheingraber, Chris
- Schneider, Simon
- Sippl, Christian
- Snoke, Arthur
- Stange, Stefan
- Stähler, Simon C.
- Sullivan, Benjamin
- Tian, Dongdong
- Trabant, Chad
- Trani, Luca
- Uieda, Leonardo
- Walker, Andrew
- Walther, Marcus
- Wassermann, Joachim
- Williams, Mark C.
- Winkelman, Andrew
- Zaccarelli, Riccardo
- Zad, Seyed Kasra Hosseini
- Zhu, Lijun
- van Driel, Martin
- van Wijk, Kasper

#### Funds

ObsPy was partially funded by the

- German Science Foundation (DFG) via grant DFG IG 16/9-1
- German Ministry for Education and Research (BMBF), GEOTECHNOLOGIEN grant 03G0646H.
- NERA project (Network of European Research Infrastructures for Earthquake Risk Assessment and Mitigation) under the European Community's Seventh Framework Programme (FP7/2007-2013) grant agreement n° 262330
- Leibniz Institute for Applied Geophysics (LIAG)
- VERCE EU-FP7 project (no. 283543)