parameters: (request:HttpRequest, project_id, domain_id)
return_statement: return JsonResponse([{
          'id': i.id,
          'creation_time': float(i.creation_time.strftime('%s')),
          'edition_time': float(i.edition_time.strftime('%s')),
          'state_id': i.interval_state_id,
          'user_id': i.user_id,
          'start_node_id': i.start_node_id,
          'end_node_id': i.end_node_id
      } for i in intervals], safe=False)
docstring: Get a collection of available sampler domains intervals.
      ---
      parameters:
       - name: domain_id
         description: Domain to list intervals for
         type: integer
         paramType: form
         required: true
      models:
        interval_entity:
          id: interval_entity
          description: A result domain interval.
          properties:
            id:
              type: integer
              description: Id of interval
            creation_time:
              type: string
              description: The point in time the interval was created
              required: true
            edition_time:
              type: string
              description: The last point in time the interval was edited.
              required: true
            state_id:
              type: integer
              description: ID of interval state
              required: true
            user_id:
              type: integer
              description: User ID of interval creator.
              required: true
      type:
        intervals:
          type: array
          items:
            $ref: interval_entity
          description: Matching intervals
          required: true
docstring_summary: Get a collection of available sampler domains intervals.
      ---
      parameters:
       - name: domain_id
         description: Domain to list intervals for
         type: integer
         paramType: form
         required: true
      models:
        interval_entity:
          id: interval_entity
          description: A result domain interval.
          properties:
            id:
              type: integer
              description: Id of interval
            creation_time:
              type: string
              description: The point in time the interval was created
              required: true
            edition_time:
              type: string
              description: The last point in time the interval was edited.
              required: true
            state_id:
              type: integer
              description: ID of interval state
              required: true
            user_id:
              type: integer
              description: User ID of interval creator.
              required: true
      type:
        intervals:
          type: array
          items:
            $ref: interval_entity
          description: Matching intervals
          required: true
docstring_tokens: Get a collection of available sampler domains intervals . --- parameters : - name : domain_id description : Domain to list intervals for type : integer paramType : form required : true models : interval_entity : id : interval_entity description : A result domain interval . properties : id : type : integer description : Id of interval creation_time : type : string description : The point in time the interval was created required : true edition_time : type : string description : The last point in time the interval was edited . required : true state_id : type : integer description : ID of interval state required : true user_id : type : integer description : User ID of interval creator . required : true type : intervals : type : array items : $ref : interval_entity description : Matching intervals required : true
function: def list_domain_intervals(request:HttpRequest, project_id, domain_id) -> JsonResponse:
      """Get a collection of available sampler domains intervals.
      ---
      parameters:
       - name: domain_id
         description: Domain to list intervals for
         type: integer
         paramType: form
         required: true
      models:
        interval_entity:
          id: interval_entity
          description: A result domain interval.
          properties:
            id:
              type: integer
              description: Id of interval
            creation_time:
              type: string
              description: The point in time the interval was created
              required: true
            edition_time:
              type: string
              description: The last point in time the interval was edited.
              required: true
            state_id:
              type: integer
              description: ID of interval state
              required: true
            user_id:
              type: integer
              description: User ID of interval creator.
              required: true
      type:
        intervals:
          type: array
          items:
            $ref: interval_entity
          description: Matching intervals
          required: true
      """
      domain_id = int(domain_id)
      intervals = SamplerInterval.objects.filter(domain_id=domain_id)
  
      return JsonResponse([{
          'id': i.id,
          'creation_time': float(i.creation_time.strftime('%s')),
          'edition_time': float(i.edition_time.strftime('%s')),
          'state_id': i.interval_state_id,
          'user_id': i.user_id,
          'start_node_id': i.start_node_id,
          'end_node_id': i.end_node_id
      } for i in intervals], safe=False)
function_tokens: def list_domain_intervals ( request : HttpRequest , project_id , domain_id ) -> JsonResponse : domain_id = int ( domain_id ) intervals = SamplerInterval . objects . filter ( domain_id = domain_id ) return JsonResponse ( [ { 'id' : i . id , 'creation_time' : float ( i . creation_time . strftime ( '%s' ) ) , 'edition_time' : float ( i . edition_time . strftime ( '%s' ) ) , 'state_id' : i . interval_state_id , 'user_id' : i . user_id , 'start_node_id' : i . start_node_id , 'end_node_id' : i . end_node_id } for i in intervals ] , safe = False )