Link Search Menu Expand Document

Equipment API endpoint

Table of contents

  1. Fields
  2. Types of equipment
    1. Data acquisition
    2. Behavioral and stimulation tools
    3. Environmental controllers
    4. Surgical equipment
    5. Miscellaneous
    6. Coordinates system options
  3. List view
  4. Add
  5. Detail
  6. Change
  7. Delete

Fields

FieldDescription
idUUID identificator formatted as a string
typestring [required]. See options below
setuprelated experimental setup ID formatted as a string [required]
notesstring [max length: 500]
date_timestring containing date (e.g. “2023-03-22”)
consumablerelated consumable ID formatted as a string
hardwaredevicerelated hardware device ID formatted as a string
coordinates_systemstring [required]. See options below
coordinates_detailsJSON object. See accepted schemas below

Types of equipment

Data acquisition

  • Amplifier: Amplifier
  • Camera, Camera
  • DataAcquisitionSystem: Data acquisition system
  • ElectroencephalographySystem: Electroencephalography system (EEG)
  • ElectromyographyMachine: Electromyography machine
  • EphysRig: Ephys rig
  • FiberPhotometrySystem: Fiber photometry system
  • ForcePlate: Force plate
  • HumiditySensor: Humidity sensor
  • LightSensor: Light sensor
  • MagneticResonanceImagingSystem: Magnetic resonance imaging (MRI) system
  • MagnetoencephalographySystem: Magnetoencephalography (MEG) system
  • Magnetometer: Magnetometer
  • Microphone: Microphone
  • Miniscope: Miniscope
  • MotionTrackingSystem: Motion tracking system
  • OphysRig: Ophys rig
  • OpticalCoherenceTomography: Optical Coherence Tomography (OCT)
  • Oscilloscope: Oscilloscope
  • Photodetector: Photodetector
  • SignalProcessingUnit: Signal processing unit
  • SinglePhotonEmissionComputedTomography: Single-photon emission computed tomography (SPECT)
  • TemperatureSensor: Temperature sensor
  • UltrasoundImagingSystem: Ultrasound imaging system

Behavioral and stimulation tools

  • BehaviorRig: Behavior rig
  • IontophoresisStimulator: Iontophoresis stimulator
  • Laser: Laser
  • LedDriver: LED Driver
  • LightEmitter: Light emitter
  • RunningWheel: Running Wheel
  • Speaker: Speaker
  • StimulationDevice: Stimulation device
  • Treadmill: Treadmill

Environmental controllers

  • AntiVibrationTable: Anti-vibration table
  • FloatingAirPlatform: Floating air platform
  • HumidityController: Humidity controller
  • NoiseIsolationChamber: Noise isolation chamber
  • ThermalController: Thermal controller

Surgical equipment

  • AnesthesiaSystem: Anesthesia system
  • InjectionSystem: Injection system
  • Micromanipulator: Micromanipulator
  • Microscope: Microscope
  • StereotaxicFrame: Stereotaxic frame
  • SurgicalPowerTool: Surgical power tool
  • PerfusionSystem: Perfusion system

Miscellaneous

  • BiosafetyCabinet: Biosafety cabinet
  • Computer: Computer
  • ElectronicComponent: Electronic component
  • FumeHood: Fume hood
  • GlassMicropipettePuller: Glass micropipette puller
  • Microcontroller: Microcontroller (e.g. Arduino)
  • Monitor: Monitor
  • SingleBoardComputer: Single-board computer (e.g. Raspberry Pi)

Coordinates system options

These are the available coordinates_system options for Equipment:

  • External_XYZ_Absolute: External XYZ Coordinates with Angles

A detailed list of the accepted schemas for the coordinates_details field, related to each coordinates_system, can be found in the Coordinates schemas page.

List view

  • Allowed portals: public, private, super
  • Request method: GET
  • URL: https://www.brainstem.org/api/private/modules/equipment
  • Data: None
  • Responses: 200 OK; 403 Not allowed; 404 Not found

Use example (using Python API)

resp = client.load_model('equipment')

Response example

{'equipment': [
    {
        'id': 'f79d84c8-6bec-40e3-b18a-5b25e57f4a09',
        'type': 'TetrodeWireElectrode',
        'notes': 'First implant',
        'setup': '0f87c229-6769-4854-83a5-c71e154246b8',
        'date_time': None,
        'consumable': 'a5f29099-2758-4163-a8e4-e5e2898e57b2',
        'hardwaredevice': None,
        'details': {
            'tetrodeCount': 1,
            'nWiresTetrode': 4,
            'wireDiameter': 33.9,
            'wireMaterial': 'tunsgten'
        },
        'coordinates_system': 'External_XYZ_Absolute',
        'coordinates_details': {
            'apCoordinate': 1.0
        }
    },
    {
        'id': 'a18dd2b1-6393-468c-9424-1bc77b9e4976',
        'type': 'TetrodeWireElectrode',
        'notes': 'Second implant',
        'setup': '0f87c229-6769-4854-83a5-c71e154246b8',
        'date_time': None,
        'consumable': None,
        'hardwaredevice': None,
        'details': {
            'tetrodeCount': 1,
            'nWiresTetrode': 4,
            'wireDiameter': 33.9,
            'wireMaterial': 'tunsgten'
        },
        'coordinates_system': 'External_XYZ_Absolute',
        'coordinates_details': {
            'x': 1.0,
            'y': 0.0,
            'xAngle': 2.0
        }
    }
]}

Add

  • Allowed portals: private, super
  • Request method: POST
  • URL: https://www.brainstem.org/api/private/modules/equipment
  • Data: JSON dictionary containing at least the required fields.
  • Responses: 201 OK; 400 Bad request; 403 Not allowed; 404 Not found

Use example (using Python API)

resp = client.save_model("equipment",  data={
    "type": "OpticFiberImplant",
    "setup": "0f87c229-6769-4854-83a5-c71e154246b8",
    "notes": "some text",
    "details": {"fiberTipShape": "flat"},
    "coordinates_system": "External_XYZ_Absolute",
    "coordinates_details": {
                "x": 1.0,
                "y": 2.0,
                "z": 3.0,
                "xAngle": 4.0,
                "yAngle": 5.0,
                "zAngle": 6.0
            }
    }
)

Response example

{'equipment': {
    'id': 'd37c9255-d5ae-47d9-b6e1-4ec760c200fb',
    'type': 'OpticFiberImplant',
    'notes': 'some text',
    'setup': '0f87c229-6769-4854-83a5-c71e154246b8',
    'date_time': None,
    'consumable': None,
    'hardwaredevice': None,
    'details': {'fiberTipShape': 'flat'},
    'coordinates_system': 'External_XYZ_Absolute',
    'coordinates_details': {
                "x": 1.0,
                "y": 2.0,
                "z": 3.0,
                "xAngle": 4.0,
                "yAngle": 5.0,
                "zAngle": 6.0
            }
    }
}

Detail

  • Allowed portals: public, private, super
  • Request method: GET
  • URL: https://www.brainstem.org/api/private/modules/equipment/<id>/
  • Data: None
  • Responses: 200 OK; 403 Not allowed; 404 Not found

Use example (using Python API)

resp = client.load_model('equipment', id='d37c9255-d5ae-47d9-b6e1-4ec760c200fb')

Response example

{'equipment': {
    'id': 'd37c9255-d5ae-47d9-b6e1-4ec760c200fb',
    'type': 'OpticFiberImplant',
    'notes': 'some text',
    'setup': '0f87c229-6769-4854-83a5-c71e154246b8',
    'date_time': None,
    'consumable': None,
    'hardwaredevice': None,
    'details': {'fiberTipShape': 'flat'},
    'coordinates_system': 'External_XYZ_Absolute',
    'coordinates_details': : {
                "x": 1.0,
                "y": 2.0,
                "z": 3.0,
                "xAngle": 4.0,
                "yAngle": 5.0,
                "zAngle": 6.0
            }
    }
}

Change

  • Allowed portals: private, super
  • Request method: PATCH
  • URL: https://www.brainstem.org/api/private/modules/equipment/<id>/
  • Data: dictionary containing the fields to be updated
  • Responses: 200 OK; 400 Bad request; 403 Not allowed; 404 Not found

Use example (using Python API)

resp = client.save_model("equipment", id="d37c9255-d5ae-47d9-b6e1-4ec760c200fb", data={"notes": "new text"})

Response example

{'equipment': {
    'id': 'd37c9255-d5ae-47d9-b6e1-4ec760c200fb',
    'type': 'OpticFiberImplant',
    'notes': 'new text',
    'setup': '0f87c229-6769-4854-83a5-c71e154246b8',
    'date_time': None,
    'consumable': None,
    'hardwaredevice': None,
    'details': {'fiberTipShape': 'flat'},
    'coordinates_system': 'External_XYZ_Absolute',
    'coordinates_details': : {
                "x": 1.0,
                "y": 2.0,
                "z": 3.0,
                "xAngle": 4.0,
                "yAngle": 5.0,
                "zAngle": 6.0
            }
    }
}

Delete

  • Allowed portals: private, super
  • Request method: DELETE
  • URL: https://www.brainstem.org/api/private/modules/equipment/<id>/
  • Data: None
  • Responses: 204 OK; 403 Not allowed; 404 Not found

Use example (using Python API)

resp = client.delete_model("equipment", id="d37c9255-d5ae-47d9-b6e1-4ec760c200fb")