// Copyright 2017 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// https://w3c.github.io/payment-handler/#paymentinstruments-interface
[
RuntimeEnabled=PaymentInstruments,
Exposed=(Window,Worker)
] interface PaymentInstruments {
[CallWith=ScriptState, RaisesException, ImplementedAs=deleteInstrument, Measure] Promise<boolean> delete(DOMString instrumentKey);
[CallWith=ScriptState, RaisesException, Measure] Promise<PaymentInstrument> get(DOMString instrumentKey);
[CallWith=ScriptState, RaisesException, Measure] Promise<sequence<DOMString>> keys();
[CallWith=ScriptState, RaisesException, Measure] Promise<boolean> has(DOMString instrumentKey);
[CallWith=ScriptState, RaisesException, Measure] Promise<undefined> set(DOMString instrumentKey, PaymentInstrument details);
[CallWith=ScriptState, RaisesException, Measure] Promise<undefined> clear();
};