[script] Using template variable is service id

I am trying to improve my script and would like to call the correct media player volume service depending on my template variable.

At the moment, the code looks like this:

alias: sony volume
sequence:
  - choose:
      - conditions:
          - condition: template
            value_template: "{{ volume == \"up\" }}"
        sequence:
          - repeat:
              count: "{{ press }}"
              sequence:
                - service: media_player.volume_up
                  data: {}
                  target:
                    entity_id: media_player.sony_ke_48a9
                - delay:
                    hours: 0
                    minutes: 0
                    seconds: 0
                    milliseconds: 0
      - conditions:
          - condition: template
            value_template: "{{ volume == \"down\" }}"
        sequence:
          - repeat:
              count: "{{ press }}"
              sequence:
                - service: media_player.volume_down
                  data: {}
                  target:
                    entity_id: media_player.sony_ke_48a9
mode: single
icon: mdi:volume-high

I would like to remove the condition and just append the volume variable to the service name but unsure how to correctly achieve this.

Managed to solve it and was easy enough.

alias: sony volume
sequence:
  - repeat:
      count: "{{ press }}"
      sequence:
        - service: media_player.volume_{{ volume }}
          data: {}
          target:
            entity_id: media_player.sony_ke_48a9
        - delay:
            hours: 0
            minutes: 0
            seconds: 0
            milliseconds: 0
mode: single
icon: mdi:volume-high

What’s the purpose of adding a delay statement whose value is zero?

        - delay:
            hours: 0
            minutes: 0
            seconds: 0
            milliseconds: 0

I was in the process of writing it. The delay will be sent as a parameter from the webhook.