1

I'd like to be able to pass a phone number to the phone application from within a preview of a scope.

  • Is that possible?
  • Is it done with action widgets?
  • Is there an example of this somewhere in JavaScript?

1 Answer 1

0

You are able to do it by specifying a tel: URI in a actions preview widget's url, e.g.:

var actions_widget = new scopes.lib.PreviewWidget("actionsId", "actions");
actions_widget.add_attribute_value(
  "actions",
  [
    {
      "id": "call",
      "label": "Call",
      "uri": "tel:+555555555"
    }
  ]
);

in the run() callback as you create a PreviewQuery

1
  • I've added your example. The widget is showing up, but empty as an orange rectangle. It also doesn't trigger the phone.
    – timaw
    Mar 2, 2016 at 0:20

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .