Can't the alarm people advise you?
There are telephone companies now who offer services without the need to have a contract with Telefonica, but I think they do this by effectively renting the lines from Telefonica at advantages rates, and then re-selling to the consumer. If you are not going to use the line for phone calls, I'm not sure whether that would be possible or not. And I'm guessing that you will still have to pay Telefonica to install the line in the first place - but I'm not certain of this.
One thing is certain - the lines are still Telefonicas. When their line is out of action, it doesn't make any difference who you get your service from.