How to pickup call use ami?

In my project, I want to pickup a ringing extension use the ami, and I send the action like this:

Action: Originate
Channel: SIP/606
Application: Pickup
Data: 608

then I get the error message “app_directed_pickup.c: pickup_exec: No target channel found for 608”. 608 is the sip extension which is ringing, and I want to use sip extension 606 to Pickup 608. Has anyone know what’s the problem? :question:

Not sure as I have never tried to do a pickup through AMI, but my thoughts are…

The Pickup() app needs a context unless it is in the same context as the ringing channel.

If you know the full channel name for the ringing channel, you could try the PickupChan app instead.

I hope this helps.

Thanks dalenoll!

Pickup through AMI doesn’t work, now I use the redirect to pickup the ringing extension. Use redirect I need to write much more codes for storing,finding and removing the ringing’s channel and destination channel, and it works now.

Hi leegoex…

Just curious , What was your solution…
I has the exact same issue…

/Best Michael