No absolute rules here, concerning time, as the above answers points out.
However, at least an experienced composer should be able to tell you how long it would take to deliver what you need and asked for. And if you had a deadline, say "I want this type of music and so long, in one week", an experienced composer would tell you if it were possible or not.
You can come up with a tune, a basic structure for a melody in 30 minutes, but then it's the rest of the work.
For me composing is a craft, like building furniture, or a house, or sculpting, and it takes time if you're gonna carve out and put the pieces together carefully. But that does not mean you need unlimited time. Around 2 days for composing/recording a piece of 3 minutes may serve as a very rough guideline, but then comes mixing, mastering and that can be 1-3 days (again extremely rough estimation). But if in a hurry, all this may be done in one day, but then it's probably not so perfect as it could be. I do both orchestral and synth based music, and orchestral, classical stuff usually needs more carefullness in instrument handling, playing technique. Sometimes I like to throw in an accoustic, original sound that needs technical processing into the computer.
And then you have to take into account that the director wants to have something changed.