diff --git a/404.html b/404.html index 6c2463e7..75fcc062 100644 --- a/404.html +++ b/404.html @@ -1,10 +1,10 @@ - WGTWO API v0 docs - WGTWO API v0 docs + WGTWO API v0 docs - WGTWO API v0 docs

404 - not found

- + diff --git a/404/index.html b/404/index.html index 6c2463e7..75fcc062 100644 --- a/404/index.html +++ b/404/index.html @@ -1,10 +1,10 @@ - WGTWO API v0 docs - WGTWO API v0 docs + WGTWO API v0 docs - WGTWO API v0 docs

404 - not found

- + diff --git a/assets/data/404/index.json b/assets/data/404/index.json index 1198f417..0eba5d26 100644 --- a/assets/data/404/index.json +++ b/assets/data/404/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":null,"context":{"__notFound":true}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":null,"context":{"__notFound":true}} \ No newline at end of file diff --git a/assets/data/call-forwarding/call-forwarding-api-reference/index.json b/assets/data/call-forwarding/call-forwarding-api-reference/index.json index a8913dda..5771c966 100644 --- a/assets/data/call-forwarding/call-forwarding-api-reference/index.json +++ b/assets/data/call-forwarding/call-forwarding-api-reference/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Call forwarding API reference","headings":[],"subtitles":[],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Call forwarding API reference","headings":[],"subtitles":[],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/data/call-forwarding/set-call-forwarding/index.json b/assets/data/call-forwarding/set-call-forwarding/index.json index 765d184b..ecead1aa 100644 --- a/assets/data/call-forwarding/set-call-forwarding/index.json +++ b/assets/data/call-forwarding/set-call-forwarding/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Set call forwarding","headings":[{"value":"How to set up call forwarding"}],"subtitles":[{"depth":1,"value":"How to set up call forwarding","anchor":"#how-to-set-up-call-forwarding"},{"depth":2,"value":"Overview","anchor":"#overview"},{"depth":2,"value":"Limitations","anchor":"#limitations"},{"depth":2,"value":"Forward all calls (unconditional) to another number","anchor":"#forward-all-calls-unconditional-to-another-number"},{"depth":2,"value":"Forward calls if busy or unavailable (conditional) to another number","anchor":"#forward-calls-if-busy-or-unavailable-conditional-to-another-number"},{"depth":2,"value":"Forward all calls (unconditional) to a trunk","anchor":"#forward-all-calls-unconditional-to-a-trunk"},{"depth":2,"value":"Forward calls if busy or unavailable or no answer (conditional) to default voicemail","anchor":"#forward-calls-if-busy-or-unavailable-or-no-answer-conditional-to-default-voicemail"},{"depth":2,"value":"Disable call forwarding","anchor":"#disable-call-forwarding"},{"depth":2,"value":"Concepts","anchor":"#concepts"}],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[{"file":"examples/grpcurl/thirdpartydev/forwarding/unconditional_to_number.sh","content":"grpcurl \\\n -H \"Authorization: Bearer ${ACCESS_TOKEN}\"\\\n -import-path . \\\n -proto wgtwo/callforward/v0/callforward.proto \\\n -d '{\n \"subscriber\": { \"e164\": \"+4672xxxxxxx\"},\n \"unconditional\": {\n \"forward_to_number\": { \"e164\": \"+4672xxxxxxx\"}\n }\n }' \\\n api.wgtwo.com:443 \\\n wgtwo.callforward.v0.CallForwardingService/SetToNumber\n"},{"file":"examples/kotlin/thirdpartydev/forwarding/src/main/kotlin/com/wgtwo/examples/thirdpartydev/forwarding/UnconditionalCallForwardingToNumber.kt","content":"package com.wgtwo.examples.thirdpartydev.forwarding\n\nimport com.wgtwo.api.v0.callforward.CallForwardingProto\nimport com.wgtwo.api.v0.callforward.CallForwardingServiceGrpc\nimport com.wgtwo.api.common.Environment\nimport com.wgtwo.api.v0.common.PhoneNumberProto\nimport com.wgtwo.api.util.auth.BearerToken\nimport com.wgtwo.api.util.auth.Channels\n\nprivate val channel = Channels.createChannel(Environment.PRODUCTION)\nprivate val credentials = BearerToken { \"MY_ACCESS_TOKEN\" } // Add your credentials\nprivate val stub = CallForwardingServiceGrpc.newBlockingStub(channel).withCallCredentials(credentials)\n\nfun main() {\n val message = with(CallForwardingProto.NumberCallForwardingRequest.newBuilder()) {\n this.subscriber = with(PhoneNumberProto.PhoneNumber.newBuilder()) {\n this.e164 = \"+4672xxxxxxx\"\n build()\n }\n this.unconditional = with(CallForwardingProto.Unconditional.newBuilder()) {\n this.forwardToNumber = with(PhoneNumberProto.PhoneNumber.newBuilder()) {\n this.e164 = \"+4672xxxxxxx\"\n build()\n }\n build()\n }\n build()\n }\n\n val result = stub.setToNumber(message)\n if (result.status == CallForwardingProto.CallForwardingResponse.Status.ACCEPTED) {\n println(\"Successfully set call forwarding\")\n } else {\n println(\"\"\"\n Failed to set call forwarding:\n status=${result.status}\n description=${result.errorMessage}\"\n \"\"\".trimIndent())\n }\n}\n"},{"file":"examples/grpcurl/thirdpartydev/forwarding/conditional_to_number.sh","content":"grpcurl \\\n -H \"Authorization: Bearer ${ACCESS_TOKEN}\"\\\n -import-path . \\\n -proto wgtwo/callforward/v0/callforward.proto \\\n -d '{\n \"subscriber\": { \"e164\": \"+4672xxxxxxx\"},\n \"conditional\": {\n \"busy\": { \"e164\": \"+4672xxxxxxx\"},\n \"unavailable\": { \"e164\": \"+4672xxxxxxx\"}\n }\n }' \\\n api.wgtwo.com:443 \\\n wgtwo.callforward.v0.CallForwardingService/SetToNumber\n"},{"file":"examples/kotlin/thirdpartydev/forwarding/src/main/kotlin/com/wgtwo/examples/thirdpartydev/forwarding/ConditionalCallForwardingToNumber.kt","content":"package com.wgtwo.examples.thirdpartydev.forwarding\n\nimport com.wgtwo.api.v0.callforward.CallForwardingProto\nimport com.wgtwo.api.v0.callforward.CallForwardingServiceGrpc\nimport com.wgtwo.api.common.Environment\nimport com.wgtwo.api.v0.common.PhoneNumberProto\nimport com.wgtwo.api.util.auth.BearerToken\nimport com.wgtwo.api.util.auth.Channels\n\nprivate val channel = Channels.createChannel(Environment.PRODUCTION)\nprivate val credentials = BearerToken { \"MY_ACCESS_TOKEN\" } // Add your credentials\nprivate val stub = CallForwardingServiceGrpc.newBlockingStub(channel).withCallCredentials(credentials)\n\nfun main() {\n val message = with(CallForwardingProto.NumberCallForwardingRequest.newBuilder()) {\n this.subscriber = with(PhoneNumberProto.PhoneNumber.newBuilder()) {\n this.e164 = \"+4672xxxxxxx\"\n build()\n }\n this.conditional = with(CallForwardingProto.Conditional.newBuilder()) {\n this.busy = with(PhoneNumberProto.PhoneNumber.newBuilder()) {\n this.e164 = \"+4672xxxxxxx\"\n build()\n }\n this.unavailable = with(PhoneNumberProto.PhoneNumber.newBuilder()) {\n this.e164 = \"+4672xxxxxxx\"\n build()\n }\n build()\n }\n build()\n }\n\n val result = stub.setToNumber(message)\n if (result.status == CallForwardingProto.CallForwardingResponse.Status.ACCEPTED) {\n println(\"Successfully set call forwarding\")\n } else {\n println(\"\"\"\n Failed to set call forwarding:\n status=${result.status}\n description=${result.errorMessage}\"\n \"\"\".trimIndent())\n }\n}\n"},{"file":"examples/grpcurl/thirdpartydev/forwarding/unconditional_to_trunk.sh","content":"grpcurl \\\n -H \"Authorization: Bearer ${ACCESS_TOKEN}\"\\\n -import-path . \\\n -proto wgtwo/callforward/v0/callforward.proto \\\n -d '{\n \"subscriber\": { \"e164\": \"+4672xxxxxxx\"},\n \"unconditional_trunk_forwarding\": {\n \"forward_to_trunk\": { \"id\": \"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\"}\n }\n }' \\\n api.wgtwo.com:443 \\\n wgtwo.callforward.v0.CallForwardingService/SetToTrunk\n"},{"file":"examples/kotlin/thirdpartydev/forwarding/src/main/kotlin/com/wgtwo/examples/thirdpartydev/forwarding/UnconditionalCallForwardingToTrunk.kt","content":"package com.wgtwo.examples.thirdpartydev.forwarding\n\nimport com.wgtwo.api.v0.callforward.CallForwardingProto\nimport com.wgtwo.api.v0.callforward.CallForwardingServiceGrpc\nimport com.wgtwo.api.common.Environment\nimport com.wgtwo.api.v0.common.PhoneNumberProto\nimport com.wgtwo.api.util.auth.BearerToken\nimport com.wgtwo.api.util.auth.Channels\n\nprivate val channel = Channels.createChannel(Environment.PRODUCTION)\nprivate val credentials = BearerToken { \"MY_ACCESS_TOKEN\" } // Add your credentials\nprivate val stub = CallForwardingServiceGrpc.newBlockingStub(channel).withCallCredentials(credentials)\n\nfun main() {\n val message = with(CallForwardingProto.TrunkCallForwardingRequest.newBuilder()) {\n this.subscriber = with(PhoneNumberProto.PhoneNumber.newBuilder()) {\n this.e164 = \"+4672xxxxxxx\"\n build()\n }\n this.unconditionalTrunkForwarding = with(CallForwardingProto.UnconditionalTrunkForwarding.newBuilder()) {\n this.forwardToTrunk = with(CallForwardingProto.Trunk.newBuilder()) {\n this.id = \"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\"\n build()\n }\n build()\n }\n build()\n }\n\n val result = stub.setToTrunk(message)\n if (result.status == CallForwardingProto.CallForwardingResponse.Status.ACCEPTED) {\n println(\"Successfully set call forwarding\")\n } else {\n println(\"\"\"\n Failed to set call forwarding:\n status=${result.status}\n description=${result.errorMessage}\"\n \"\"\".trimIndent())\n }\n}\n"},{"file":"examples/grpcurl/thirdpartydev/forwarding/conditional_to_voicemail.sh","content":"grpcurl \\\n -H \"Authorization: Bearer ${ACCESS_TOKEN}\"\\\n -import-path . \\\n -proto wgtwo/callforward/v0/callforward.proto \\\n -d '{\n \"subscriber\": { \"e164\": \"+4672xxxxxxx\"},\n \"conditional\": {\n \"busy\": { \"e164\": \"+4672xxxxxxx\"},\n \"unavailable\": { \"e164\": \"+4672xxxxxxx\"},\n \"no_reply\": { \"e164\": \"+4672xxxxxxx\"}\n }\n }' \\\n api.wgtwo.com:443 \\\n wgtwo.callforward.v0.CallForwardingService/SetToVoicemail\n"},{"file":"examples/kotlin/thirdpartydev/forwarding/src/main/kotlin/com/wgtwo/examples/thirdpartydev/forwarding/ConditionalCallForwardingToVoicemail.kt","content":"package com.wgtwo.examples.thirdpartydev.forwarding\n\nimport com.wgtwo.api.v0.callforward.CallForwardingProto\nimport com.wgtwo.api.v0.callforward.CallForwardingServiceGrpc\nimport com.wgtwo.api.common.Environment\nimport com.wgtwo.api.v0.common.PhoneNumberProto\nimport com.wgtwo.api.util.auth.BearerToken\nimport com.wgtwo.api.util.auth.Channels\n\nprivate val channel = Channels.createChannel(Environment.PRODUCTION)\nprivate val credentials = BearerToken { \"MY_ACCESS_TOKEN\" } // Add your credentials\nprivate val stub = CallForwardingServiceGrpc.newBlockingStub(channel).withCallCredentials(credentials)\n\nfun main() {\n val message = with(CallForwardingProto.VoicemailCallForwardingRequest.newBuilder()) {\n this.subscriber = with(PhoneNumberProto.PhoneNumber.newBuilder()) {\n this.e164 = \"+4672xxxxxxx\"\n build()\n }\n build()\n }\n\n val result = stub.setToVoicemail(message)\n if (result.status == CallForwardingProto.CallForwardingResponse.Status.ACCEPTED) {\n println(\"Successfully set call forwarding\")\n } else {\n println(\"\"\"\n Failed to set call forwarding:\n status=${result.status}\n description=${result.errorMessage}\"\n \"\"\".trimIndent())\n }\n}\n"},{"file":"examples/grpcurl/thirdpartydev/forwarding/disable.sh","content":"grpcurl \\\n -H \"Authorization: Bearer ${ACCESS_TOKEN}\"\\\n -import-path . \\\n -proto wgtwo/callforward/v0/callforward.proto \\\n -d '{\n \"subscriber\": { \"e164\": \"+4672xxxxxxx\"}\n }' \\\n api.wgtwo.com:443 \\\n wgtwo.callforward.v0.CallForwardingService/Disable\n"},{"file":"examples/kotlin/thirdpartydev/forwarding/src/main/kotlin/com/wgtwo/examples/thirdpartydev/forwarding/DisableCallForwarding.kt","content":"package com.wgtwo.examples.thirdpartydev.forwarding\n\nimport com.wgtwo.api.v0.callforward.CallForwardingProto\nimport com.wgtwo.api.v0.callforward.CallForwardingServiceGrpc\nimport com.wgtwo.api.common.Environment\nimport com.wgtwo.api.v0.common.PhoneNumberProto\nimport com.wgtwo.api.util.auth.BearerToken\nimport com.wgtwo.api.util.auth.Channels\n\nprivate val channel = Channels.createChannel(Environment.PRODUCTION)\nprivate val credentials = BearerToken { \"MY_ACCESS_TOKEN\" } // Add your credentials\nprivate val stub = CallForwardingServiceGrpc.newBlockingStub(channel).withCallCredentials(credentials)\n\nfun main() {\n val message = with(CallForwardingProto.DisableCallForwardingRequest.newBuilder()) {\n this.subscriber = with(PhoneNumberProto.PhoneNumber.newBuilder()) {\n this.e164 = \"+4672xxxxxxx\"\n build()\n }\n build()\n }\n\n val result = stub.disable(message)\n if (result.status == CallForwardingProto.CallForwardingResponse.Status.ACCEPTED) {\n println(\"Successfully disabled call forwarding\")\n } else {\n println(\"\"\"\n Failure to disable call forwarding:\n status=${result.status}\n description=${result.errorMessage}\"\n \"\"\".trimIndent())\n }\n}\n"}]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Set call forwarding","headings":[{"value":"How to set up call forwarding"}],"subtitles":[{"depth":1,"value":"How to set up call forwarding","anchor":"#how-to-set-up-call-forwarding"},{"depth":2,"value":"Overview","anchor":"#overview"},{"depth":2,"value":"Limitations","anchor":"#limitations"},{"depth":2,"value":"Forward all calls (unconditional) to another number","anchor":"#forward-all-calls-unconditional-to-another-number"},{"depth":2,"value":"Forward calls if busy or unavailable (conditional) to another number","anchor":"#forward-calls-if-busy-or-unavailable-conditional-to-another-number"},{"depth":2,"value":"Forward all calls (unconditional) to a trunk","anchor":"#forward-all-calls-unconditional-to-a-trunk"},{"depth":2,"value":"Forward calls if busy or unavailable or no answer (conditional) to default voicemail","anchor":"#forward-calls-if-busy-or-unavailable-or-no-answer-conditional-to-default-voicemail"},{"depth":2,"value":"Disable call forwarding","anchor":"#disable-call-forwarding"},{"depth":2,"value":"Concepts","anchor":"#concepts"}],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[{"file":"examples/grpcurl/thirdpartydev/forwarding/unconditional_to_number.sh","content":"grpcurl \\\n -H \"Authorization: Bearer ${ACCESS_TOKEN}\"\\\n -import-path . \\\n -proto wgtwo/callforward/v0/callforward.proto \\\n -d '{\n \"subscriber\": { \"e164\": \"+4672xxxxxxx\"},\n \"unconditional\": {\n \"forward_to_number\": { \"e164\": \"+4672xxxxxxx\"}\n }\n }' \\\n api.wgtwo.com:443 \\\n wgtwo.callforward.v0.CallForwardingService/SetToNumber\n"},{"file":"examples/kotlin/thirdpartydev/forwarding/src/main/kotlin/com/wgtwo/examples/thirdpartydev/forwarding/UnconditionalCallForwardingToNumber.kt","content":"package com.wgtwo.examples.thirdpartydev.forwarding\n\nimport com.wgtwo.api.v0.callforward.CallForwardingProto\nimport com.wgtwo.api.v0.callforward.CallForwardingServiceGrpc\nimport com.wgtwo.api.common.Environment\nimport com.wgtwo.api.v0.common.PhoneNumberProto\nimport com.wgtwo.api.util.auth.BearerToken\nimport com.wgtwo.api.util.auth.Channels\n\nprivate val channel = Channels.createChannel(Environment.PRODUCTION)\nprivate val credentials = BearerToken { \"MY_ACCESS_TOKEN\" } // Add your credentials\nprivate val stub = CallForwardingServiceGrpc.newBlockingStub(channel).withCallCredentials(credentials)\n\nfun main() {\n val message = with(CallForwardingProto.NumberCallForwardingRequest.newBuilder()) {\n this.subscriber = with(PhoneNumberProto.PhoneNumber.newBuilder()) {\n this.e164 = \"+4672xxxxxxx\"\n build()\n }\n this.unconditional = with(CallForwardingProto.Unconditional.newBuilder()) {\n this.forwardToNumber = with(PhoneNumberProto.PhoneNumber.newBuilder()) {\n this.e164 = \"+4672xxxxxxx\"\n build()\n }\n build()\n }\n build()\n }\n\n val result = stub.setToNumber(message)\n if (result.status == CallForwardingProto.CallForwardingResponse.Status.ACCEPTED) {\n println(\"Successfully set call forwarding\")\n } else {\n println(\"\"\"\n Failed to set call forwarding:\n status=${result.status}\n description=${result.errorMessage}\"\n \"\"\".trimIndent())\n }\n}\n"},{"file":"examples/grpcurl/thirdpartydev/forwarding/conditional_to_number.sh","content":"grpcurl \\\n -H \"Authorization: Bearer ${ACCESS_TOKEN}\"\\\n -import-path . \\\n -proto wgtwo/callforward/v0/callforward.proto \\\n -d '{\n \"subscriber\": { \"e164\": \"+4672xxxxxxx\"},\n \"conditional\": {\n \"busy\": { \"e164\": \"+4672xxxxxxx\"},\n \"unavailable\": { \"e164\": \"+4672xxxxxxx\"}\n }\n }' \\\n api.wgtwo.com:443 \\\n wgtwo.callforward.v0.CallForwardingService/SetToNumber\n"},{"file":"examples/kotlin/thirdpartydev/forwarding/src/main/kotlin/com/wgtwo/examples/thirdpartydev/forwarding/ConditionalCallForwardingToNumber.kt","content":"package com.wgtwo.examples.thirdpartydev.forwarding\n\nimport com.wgtwo.api.v0.callforward.CallForwardingProto\nimport com.wgtwo.api.v0.callforward.CallForwardingServiceGrpc\nimport com.wgtwo.api.common.Environment\nimport com.wgtwo.api.v0.common.PhoneNumberProto\nimport com.wgtwo.api.util.auth.BearerToken\nimport com.wgtwo.api.util.auth.Channels\n\nprivate val channel = Channels.createChannel(Environment.PRODUCTION)\nprivate val credentials = BearerToken { \"MY_ACCESS_TOKEN\" } // Add your credentials\nprivate val stub = CallForwardingServiceGrpc.newBlockingStub(channel).withCallCredentials(credentials)\n\nfun main() {\n val message = with(CallForwardingProto.NumberCallForwardingRequest.newBuilder()) {\n this.subscriber = with(PhoneNumberProto.PhoneNumber.newBuilder()) {\n this.e164 = \"+4672xxxxxxx\"\n build()\n }\n this.conditional = with(CallForwardingProto.Conditional.newBuilder()) {\n this.busy = with(PhoneNumberProto.PhoneNumber.newBuilder()) {\n this.e164 = \"+4672xxxxxxx\"\n build()\n }\n this.unavailable = with(PhoneNumberProto.PhoneNumber.newBuilder()) {\n this.e164 = \"+4672xxxxxxx\"\n build()\n }\n build()\n }\n build()\n }\n\n val result = stub.setToNumber(message)\n if (result.status == CallForwardingProto.CallForwardingResponse.Status.ACCEPTED) {\n println(\"Successfully set call forwarding\")\n } else {\n println(\"\"\"\n Failed to set call forwarding:\n status=${result.status}\n description=${result.errorMessage}\"\n \"\"\".trimIndent())\n }\n}\n"},{"file":"examples/grpcurl/thirdpartydev/forwarding/unconditional_to_trunk.sh","content":"grpcurl \\\n -H \"Authorization: Bearer ${ACCESS_TOKEN}\"\\\n -import-path . \\\n -proto wgtwo/callforward/v0/callforward.proto \\\n -d '{\n \"subscriber\": { \"e164\": \"+4672xxxxxxx\"},\n \"unconditional_trunk_forwarding\": {\n \"forward_to_trunk\": { \"id\": \"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\"}\n }\n }' \\\n api.wgtwo.com:443 \\\n wgtwo.callforward.v0.CallForwardingService/SetToTrunk\n"},{"file":"examples/kotlin/thirdpartydev/forwarding/src/main/kotlin/com/wgtwo/examples/thirdpartydev/forwarding/UnconditionalCallForwardingToTrunk.kt","content":"package com.wgtwo.examples.thirdpartydev.forwarding\n\nimport com.wgtwo.api.v0.callforward.CallForwardingProto\nimport com.wgtwo.api.v0.callforward.CallForwardingServiceGrpc\nimport com.wgtwo.api.common.Environment\nimport com.wgtwo.api.v0.common.PhoneNumberProto\nimport com.wgtwo.api.util.auth.BearerToken\nimport com.wgtwo.api.util.auth.Channels\n\nprivate val channel = Channels.createChannel(Environment.PRODUCTION)\nprivate val credentials = BearerToken { \"MY_ACCESS_TOKEN\" } // Add your credentials\nprivate val stub = CallForwardingServiceGrpc.newBlockingStub(channel).withCallCredentials(credentials)\n\nfun main() {\n val message = with(CallForwardingProto.TrunkCallForwardingRequest.newBuilder()) {\n this.subscriber = with(PhoneNumberProto.PhoneNumber.newBuilder()) {\n this.e164 = \"+4672xxxxxxx\"\n build()\n }\n this.unconditionalTrunkForwarding = with(CallForwardingProto.UnconditionalTrunkForwarding.newBuilder()) {\n this.forwardToTrunk = with(CallForwardingProto.Trunk.newBuilder()) {\n this.id = \"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\"\n build()\n }\n build()\n }\n build()\n }\n\n val result = stub.setToTrunk(message)\n if (result.status == CallForwardingProto.CallForwardingResponse.Status.ACCEPTED) {\n println(\"Successfully set call forwarding\")\n } else {\n println(\"\"\"\n Failed to set call forwarding:\n status=${result.status}\n description=${result.errorMessage}\"\n \"\"\".trimIndent())\n }\n}\n"},{"file":"examples/grpcurl/thirdpartydev/forwarding/conditional_to_voicemail.sh","content":"grpcurl \\\n -H \"Authorization: Bearer ${ACCESS_TOKEN}\"\\\n -import-path . \\\n -proto wgtwo/callforward/v0/callforward.proto \\\n -d '{\n \"subscriber\": { \"e164\": \"+4672xxxxxxx\"},\n \"conditional\": {\n \"busy\": { \"e164\": \"+4672xxxxxxx\"},\n \"unavailable\": { \"e164\": \"+4672xxxxxxx\"},\n \"no_reply\": { \"e164\": \"+4672xxxxxxx\"}\n }\n }' \\\n api.wgtwo.com:443 \\\n wgtwo.callforward.v0.CallForwardingService/SetToVoicemail\n"},{"file":"examples/kotlin/thirdpartydev/forwarding/src/main/kotlin/com/wgtwo/examples/thirdpartydev/forwarding/ConditionalCallForwardingToVoicemail.kt","content":"package com.wgtwo.examples.thirdpartydev.forwarding\n\nimport com.wgtwo.api.v0.callforward.CallForwardingProto\nimport com.wgtwo.api.v0.callforward.CallForwardingServiceGrpc\nimport com.wgtwo.api.common.Environment\nimport com.wgtwo.api.v0.common.PhoneNumberProto\nimport com.wgtwo.api.util.auth.BearerToken\nimport com.wgtwo.api.util.auth.Channels\n\nprivate val channel = Channels.createChannel(Environment.PRODUCTION)\nprivate val credentials = BearerToken { \"MY_ACCESS_TOKEN\" } // Add your credentials\nprivate val stub = CallForwardingServiceGrpc.newBlockingStub(channel).withCallCredentials(credentials)\n\nfun main() {\n val message = with(CallForwardingProto.VoicemailCallForwardingRequest.newBuilder()) {\n this.subscriber = with(PhoneNumberProto.PhoneNumber.newBuilder()) {\n this.e164 = \"+4672xxxxxxx\"\n build()\n }\n build()\n }\n\n val result = stub.setToVoicemail(message)\n if (result.status == CallForwardingProto.CallForwardingResponse.Status.ACCEPTED) {\n println(\"Successfully set call forwarding\")\n } else {\n println(\"\"\"\n Failed to set call forwarding:\n status=${result.status}\n description=${result.errorMessage}\"\n \"\"\".trimIndent())\n }\n}\n"},{"file":"examples/grpcurl/thirdpartydev/forwarding/disable.sh","content":"grpcurl \\\n -H \"Authorization: Bearer ${ACCESS_TOKEN}\"\\\n -import-path . \\\n -proto wgtwo/callforward/v0/callforward.proto \\\n -d '{\n \"subscriber\": { \"e164\": \"+4672xxxxxxx\"}\n }' \\\n api.wgtwo.com:443 \\\n wgtwo.callforward.v0.CallForwardingService/Disable\n"},{"file":"examples/kotlin/thirdpartydev/forwarding/src/main/kotlin/com/wgtwo/examples/thirdpartydev/forwarding/DisableCallForwarding.kt","content":"package com.wgtwo.examples.thirdpartydev.forwarding\n\nimport com.wgtwo.api.v0.callforward.CallForwardingProto\nimport com.wgtwo.api.v0.callforward.CallForwardingServiceGrpc\nimport com.wgtwo.api.common.Environment\nimport com.wgtwo.api.v0.common.PhoneNumberProto\nimport com.wgtwo.api.util.auth.BearerToken\nimport com.wgtwo.api.util.auth.Channels\n\nprivate val channel = Channels.createChannel(Environment.PRODUCTION)\nprivate val credentials = BearerToken { \"MY_ACCESS_TOKEN\" } // Add your credentials\nprivate val stub = CallForwardingServiceGrpc.newBlockingStub(channel).withCallCredentials(credentials)\n\nfun main() {\n val message = with(CallForwardingProto.DisableCallForwardingRequest.newBuilder()) {\n this.subscriber = with(PhoneNumberProto.PhoneNumber.newBuilder()) {\n this.e164 = \"+4672xxxxxxx\"\n build()\n }\n build()\n }\n\n val result = stub.disable(message)\n if (result.status == CallForwardingProto.CallForwardingResponse.Status.ACCEPTED) {\n println(\"Successfully disabled call forwarding\")\n } else {\n println(\"\"\"\n Failure to disable call forwarding:\n status=${result.status}\n description=${result.errorMessage}\"\n \"\"\".trimIndent())\n }\n}\n"}]}},"context":{}} \ No newline at end of file diff --git a/assets/data/events/configuration-and-types/index.json b/assets/data/events/configuration-and-types/index.json index 289e5014..59978400 100644 --- a/assets/data/events/configuration-and-types/index.json +++ b/assets/data/events/configuration-and-types/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Configuration and types","headings":[{"value":"Configuration and types"}],"subtitles":[{"depth":1,"value":"Configuration and types","anchor":"#configuration-and-types"},{"depth":2,"value":"Recommended production configuration","anchor":"#recommended-production-configuration"},{"depth":2,"value":"Start position","anchor":"#start-position"},{"depth":4,"value":"Options","anchor":"#options"},{"depth":2,"value":"Configuration","anchor":"#configuration"},{"depth":3,"value":"Manual acks","anchor":"#manual-acks"},{"depth":4,"value":"Options","anchor":"#options-1"},{"depth":3,"value":"Max in-flight","anchor":"#max-in-flight"},{"depth":2,"value":"Subscription types","anchor":"#subscription-types"},{"depth":3,"value":"Regular","anchor":"#regular"},{"depth":4,"value":"Mandatory input","anchor":"#mandatory-input"},{"depth":4,"value":"Optional input","anchor":"#optional-input"},{"depth":3,"value":"Durable","anchor":"#durable"},{"depth":4,"value":"Mandatory input","anchor":"#mandatory-input-1"},{"depth":4,"value":"Optional input","anchor":"#optional-input-1"},{"depth":3,"value":"Queue","anchor":"#queue"},{"depth":4,"value":"Mandatory input","anchor":"#mandatory-input-2"},{"depth":4,"value":"Optional input","anchor":"#optional-input-2"},{"depth":3,"value":"Queue/Durable","anchor":"#queuedurable"},{"depth":4,"value":"Mandatory input","anchor":"#mandatory-input-3"},{"depth":4,"value":"Optional input","anchor":"#optional-input-3"}],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Configuration and types","headings":[{"value":"Configuration and types"}],"subtitles":[{"depth":1,"value":"Configuration and types","anchor":"#configuration-and-types"},{"depth":2,"value":"Recommended production configuration","anchor":"#recommended-production-configuration"},{"depth":2,"value":"Start position","anchor":"#start-position"},{"depth":4,"value":"Options","anchor":"#options"},{"depth":2,"value":"Configuration","anchor":"#configuration"},{"depth":3,"value":"Manual acks","anchor":"#manual-acks"},{"depth":4,"value":"Options","anchor":"#options-1"},{"depth":3,"value":"Max in-flight","anchor":"#max-in-flight"},{"depth":2,"value":"Subscription types","anchor":"#subscription-types"},{"depth":3,"value":"Regular","anchor":"#regular"},{"depth":4,"value":"Mandatory input","anchor":"#mandatory-input"},{"depth":4,"value":"Optional input","anchor":"#optional-input"},{"depth":3,"value":"Durable","anchor":"#durable"},{"depth":4,"value":"Mandatory input","anchor":"#mandatory-input-1"},{"depth":4,"value":"Optional input","anchor":"#optional-input-1"},{"depth":3,"value":"Queue","anchor":"#queue"},{"depth":4,"value":"Mandatory input","anchor":"#mandatory-input-2"},{"depth":4,"value":"Optional input","anchor":"#optional-input-2"},{"depth":3,"value":"Queue/Durable","anchor":"#queuedurable"},{"depth":4,"value":"Mandatory input","anchor":"#mandatory-input-3"},{"depth":4,"value":"Optional input","anchor":"#optional-input-3"}],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/data/events/events-api-reference/index.json b/assets/data/events/events-api-reference/index.json index e8e47a17..36958dcb 100644 --- a/assets/data/events/events-api-reference/index.json +++ b/assets/data/events/events-api-reference/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Events API reference","headings":[],"subtitles":[],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Events API reference","headings":[],"subtitles":[],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/data/events/listen-for-events/index.json b/assets/data/events/listen-for-events/index.json index 2dfd67cf..a514184c 100644 --- a/assets/data/events/listen-for-events/index.json +++ b/assets/data/events/listen-for-events/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Listen for events","headings":[{"value":"How to listen for Events"}],"subtitles":[{"depth":1,"value":"How to listen for Events","anchor":"#how-to-listen-for-events"},{"depth":2,"value":"Overview","anchor":"#overview"},{"depth":2,"value":"Event types","anchor":"#event-types"},{"depth":4,"value":"Consent revoke","anchor":"#consent-revoke"},{"depth":4,"value":"Handset update","anchor":"#handset-update"},{"depth":4,"value":"Location update","anchor":"#location-update"},{"depth":4,"value":"Roaming","anchor":"#roaming"},{"depth":4,"value":"Sms","anchor":"#sms"},{"depth":4,"value":"Sms delivery report","anchor":"#sms-delivery-report"},{"depth":4,"value":"Voice","anchor":"#voice"},{"depth":4,"value":"Voicemail","anchor":"#voicemail"},{"depth":2,"value":"Listen for events","anchor":"#listen-for-events"},{"depth":2,"value":"Manual acknowledge","anchor":"#manual-acknowledge"},{"depth":2,"value":"Concepts","anchor":"#concepts"}],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[{"file":"examples/grpcurl/thirdpartydev/events/get-events.sh","content":"# Access token must be obtained via the client credentials flow\ngrpcurl \\\n -H \"Authorization: Bearer ${ACCESS_TOKEN}\"\\\n -import-path . \\\n -proto wgtwo/events/v0/events.proto \\\n -d '\n {\n \"type\": [\"VOICE_EVENT\"]\n }\n ' \\\n api.wgtwo.com:443 \\\n wgtwo.events.v0.EventsService.Subscribe\n"},{"file":"examples/kotlin/thirdpartydev/events/src/main/kotlin/com/wgtwo/examples/thirdpartydev/events/GetEvents.kt","content":"package com.wgtwo.examples.thirdpartydev.events\n\nimport com.wgtwo.api.common.Environment\nimport com.wgtwo.api.v0.events.EventsProto\nimport com.wgtwo.api.v0.events.EventsServiceGrpc\nimport com.wgtwo.api.util.auth.Channels\nimport com.wgtwo.api.util.auth.BearerToken\nimport io.grpc.stub.StreamObserver\n\nprivate val channel = Channels.createChannel(Environment.PRODUCTION)\nprivate val credentials = BearerToken { \"MY_ACCESS_TOKEN\" } // Add your _client credentials_ access token (not user access token)\nprivate val stub = EventsServiceGrpc.newStub(channel).withCallCredentials(credentials)\n\nfun main() {\n val request = EventsProto.SubscribeEventsRequest.newBuilder()\n .addType(EventsProto.EventType.VOICE_EVENT)\n .addType(EventsProto.EventType.VOICEMAIL_EVENT)\n .build()\n stub.subscribe(request, object : StreamObserver {\n override fun onNext(response: EventsProto.SubscribeEventsResponse) {\n println(\"Received event of type: ${response.event.eventCase}\")\n }\n\n override fun onError(throwable: Throwable) {\n println(\"Got error: ${throwable.message}\")\n // TODO: Reconnect\n }\n\n override fun onCompleted() {\n println(\"Connection closed by the server\")\n }\n })\n // Wait for stream to close\n try { Thread.currentThread().join() } catch (e: InterruptedException) {}\n}\n"},{"file":"examples/kotlin/thirdpartydev/events/src/main/kotlin/com/wgtwo/examples/thirdpartydev/events/GetEventsManualAck.kt","content":"package com.wgtwo.examples.thirdpartydev.events\n\nimport com.wgtwo.api.common.Environment\nimport com.wgtwo.api.v0.events.EventsProto\nimport com.wgtwo.api.v0.events.EventsServiceGrpc\nimport com.wgtwo.api.util.auth.Channels\nimport com.wgtwo.api.util.auth.BearerToken\nimport io.grpc.stub.StreamObserver\nimport com.google.protobuf.util.Durations\n\nprivate val channel = Channels.createChannel(Environment.PRODUCTION)\nprivate val credentials = BearerToken { \"MY_ACCESS_TOKEN\" } // Add your _client credentials_ access token (not user access token)\nprivate val stub = EventsServiceGrpc.newStub(channel).withCallCredentials(credentials)\n\nfun main() {\n val request = EventsProto.SubscribeEventsRequest.newBuilder()\n .addType(EventsProto.EventType.VOICE_EVENT)\n .addType(EventsProto.EventType.VOICEMAIL_EVENT)\n .setManualAck(EventsProto.ManualAckConfig.newBuilder()\n .setEnable(true)\n .setTimeout(Durations.fromSeconds(15))\n .build()\n )\n .build()\n stub.subscribe(request, object : StreamObserver {\n override fun onNext(response: EventsProto.SubscribeEventsResponse) {\n println(\"Received event of type: ${response.event.eventCase}\")\n acknowledge(response.event)\n }\n\n override fun onError(throwable: Throwable) {\n println(\"Got error: ${throwable.message}\")\n // TODO: Reconnect\n }\n\n override fun onCompleted() {\n println(\"Connection closed by the server\")\n }\n })\n // Wait for stream to close\n try { Thread.currentThread().join() } catch (e: InterruptedException) {}\n}\n\nfun acknowledge(event: EventsProto.Event) {\n val request = EventsProto.AckRequest.newBuilder()\n .setSequence(event.metadata.sequence)\n .setInbox(event.metadata.ackInbox)\n .build()\n stub.ack(request, object : StreamObserver {\n override fun onNext(response: EventsProto.AckResponse) {\n println(\"Event successfully acknowledged\")\n }\n\n override fun onError(throwable: Throwable) {\n println(\"Error acknowledging event: ${throwable.message}\")\n }\n\n override fun onCompleted() {}\n })\n}\n"}]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Listen for events","headings":[{"value":"How to listen for Events"}],"subtitles":[{"depth":1,"value":"How to listen for Events","anchor":"#how-to-listen-for-events"},{"depth":2,"value":"Overview","anchor":"#overview"},{"depth":2,"value":"Event types","anchor":"#event-types"},{"depth":4,"value":"Consent revoke","anchor":"#consent-revoke"},{"depth":4,"value":"Handset update","anchor":"#handset-update"},{"depth":4,"value":"Location update","anchor":"#location-update"},{"depth":4,"value":"Roaming","anchor":"#roaming"},{"depth":4,"value":"Sms","anchor":"#sms"},{"depth":4,"value":"Sms delivery report","anchor":"#sms-delivery-report"},{"depth":4,"value":"Voice","anchor":"#voice"},{"depth":4,"value":"Voicemail","anchor":"#voicemail"},{"depth":2,"value":"Listen for events","anchor":"#listen-for-events"},{"depth":2,"value":"Manual acknowledge","anchor":"#manual-acknowledge"},{"depth":2,"value":"Concepts","anchor":"#concepts"}],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[{"file":"examples/grpcurl/thirdpartydev/events/get-events.sh","content":"# Access token must be obtained via the client credentials flow\ngrpcurl \\\n -H \"Authorization: Bearer ${ACCESS_TOKEN}\"\\\n -import-path . \\\n -proto wgtwo/events/v0/events.proto \\\n -d '\n {\n \"type\": [\"VOICE_EVENT\"]\n }\n ' \\\n api.wgtwo.com:443 \\\n wgtwo.events.v0.EventsService.Subscribe\n"},{"file":"examples/kotlin/thirdpartydev/events/src/main/kotlin/com/wgtwo/examples/thirdpartydev/events/GetEvents.kt","content":"package com.wgtwo.examples.thirdpartydev.events\n\nimport com.wgtwo.api.common.Environment\nimport com.wgtwo.api.v0.events.EventsProto\nimport com.wgtwo.api.v0.events.EventsServiceGrpc\nimport com.wgtwo.api.util.auth.Channels\nimport com.wgtwo.api.util.auth.BearerToken\nimport io.grpc.stub.StreamObserver\n\nprivate val channel = Channels.createChannel(Environment.PRODUCTION)\nprivate val credentials = BearerToken { \"MY_ACCESS_TOKEN\" } // Add your _client credentials_ access token (not user access token)\nprivate val stub = EventsServiceGrpc.newStub(channel).withCallCredentials(credentials)\n\nfun main() {\n val request = EventsProto.SubscribeEventsRequest.newBuilder()\n .addType(EventsProto.EventType.VOICE_EVENT)\n .addType(EventsProto.EventType.VOICEMAIL_EVENT)\n .build()\n stub.subscribe(request, object : StreamObserver {\n override fun onNext(response: EventsProto.SubscribeEventsResponse) {\n println(\"Received event of type: ${response.event.eventCase}\")\n }\n\n override fun onError(throwable: Throwable) {\n println(\"Got error: ${throwable.message}\")\n // TODO: Reconnect\n }\n\n override fun onCompleted() {\n println(\"Connection closed by the server\")\n }\n })\n // Wait for stream to close\n try { Thread.currentThread().join() } catch (e: InterruptedException) {}\n}\n"},{"file":"examples/kotlin/thirdpartydev/events/src/main/kotlin/com/wgtwo/examples/thirdpartydev/events/GetEventsManualAck.kt","content":"package com.wgtwo.examples.thirdpartydev.events\n\nimport com.wgtwo.api.common.Environment\nimport com.wgtwo.api.v0.events.EventsProto\nimport com.wgtwo.api.v0.events.EventsServiceGrpc\nimport com.wgtwo.api.util.auth.Channels\nimport com.wgtwo.api.util.auth.BearerToken\nimport io.grpc.stub.StreamObserver\nimport com.google.protobuf.util.Durations\n\nprivate val channel = Channels.createChannel(Environment.PRODUCTION)\nprivate val credentials = BearerToken { \"MY_ACCESS_TOKEN\" } // Add your _client credentials_ access token (not user access token)\nprivate val stub = EventsServiceGrpc.newStub(channel).withCallCredentials(credentials)\n\nfun main() {\n val request = EventsProto.SubscribeEventsRequest.newBuilder()\n .addType(EventsProto.EventType.VOICE_EVENT)\n .addType(EventsProto.EventType.VOICEMAIL_EVENT)\n .setManualAck(EventsProto.ManualAckConfig.newBuilder()\n .setEnable(true)\n .setTimeout(Durations.fromSeconds(15))\n .build()\n )\n .build()\n stub.subscribe(request, object : StreamObserver {\n override fun onNext(response: EventsProto.SubscribeEventsResponse) {\n println(\"Received event of type: ${response.event.eventCase}\")\n acknowledge(response.event)\n }\n\n override fun onError(throwable: Throwable) {\n println(\"Got error: ${throwable.message}\")\n // TODO: Reconnect\n }\n\n override fun onCompleted() {\n println(\"Connection closed by the server\")\n }\n })\n // Wait for stream to close\n try { Thread.currentThread().join() } catch (e: InterruptedException) {}\n}\n\nfun acknowledge(event: EventsProto.Event) {\n val request = EventsProto.AckRequest.newBuilder()\n .setSequence(event.metadata.sequence)\n .setInbox(event.metadata.ackInbox)\n .build()\n stub.ack(request, object : StreamObserver {\n override fun onNext(response: EventsProto.AckResponse) {\n println(\"Event successfully acknowledged\")\n }\n\n override fun onError(throwable: Throwable) {\n println(\"Error acknowledging event: ${throwable.message}\")\n }\n\n override fun onCompleted() {}\n })\n}\n"}]}},"context":{}} \ No newline at end of file diff --git a/assets/data/index.json b/assets/data/index.json index 5ae10db5..d6e6b520 100644 --- a/assets/data/index.json +++ b/assets/data/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":null,"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":null,"context":{}} \ No newline at end of file diff --git a/assets/data/intro/api-structure-and-libraries/index.json b/assets/data/intro/api-structure-and-libraries/index.json index d0542969..d0729176 100644 --- a/assets/data/intro/api-structure-and-libraries/index.json +++ b/assets/data/intro/api-structure-and-libraries/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"API structure and libraries","headings":[{"value":"API Structure and Libraries"}],"subtitles":[{"depth":1,"value":"API Structure and Libraries","anchor":"#api-structure-and-libraries"},{"depth":2,"value":"gRPC","anchor":"#grpc"},{"depth":2,"value":"REST-like","anchor":"#rest-like"},{"depth":2,"value":"Libraries","anchor":"#libraries"},{"depth":3,"value":"Go","anchor":"#go"},{"depth":3,"value":"Java / Kotlin using Maven","anchor":"#java--kotlin-using-maven"}],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"API structure and libraries","headings":[{"value":"API Structure and Libraries"}],"subtitles":[{"depth":1,"value":"API Structure and Libraries","anchor":"#api-structure-and-libraries"},{"depth":2,"value":"gRPC","anchor":"#grpc"},{"depth":2,"value":"REST-like","anchor":"#rest-like"},{"depth":2,"value":"Libraries","anchor":"#libraries"},{"depth":3,"value":"Go","anchor":"#go"},{"depth":3,"value":"Java / Kotlin using Maven","anchor":"#java--kotlin-using-maven"}],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/data/intro/get-started/index.json b/assets/data/intro/get-started/index.json index ce5d7019..ebb18738 100644 --- a/assets/data/intro/get-started/index.json +++ b/assets/data/intro/get-started/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Get started","headings":[{"value":"Get started"}],"subtitles":[{"depth":1,"value":"Get started","anchor":"#get-started"},{"depth":2,"value":"Download proto descriptions","anchor":"#download-proto-descriptions"},{"depth":2,"value":"Set up gRPCurl","anchor":"#set-up-grpcurl"},{"depth":2,"value":"Sandbox environment","anchor":"#sandbox-environment"},{"depth":3,"value":"Setup event streaming","anchor":"#setup-event-streaming"},{"depth":3,"value":"Explore the API","anchor":"#explore-the-api"},{"depth":2,"value":"Production environment","anchor":"#production-environment"},{"depth":3,"value":"Create OAuth 2.0 client","anchor":"#create-oauth-20-client"},{"depth":3,"value":"Get access token (using the Client Credentials Flow)","anchor":"#get-access-token-using-the-client-credentials-flow"},{"depth":3,"value":"Setup stream listening for events","anchor":"#setup-stream-listening-for-events"},{"depth":4,"value":"Example code for Go","anchor":"#example-code-for-go"},{"depth":5,"value":"Download and run code example","anchor":"#download-and-run-code-example"},{"depth":2,"value":"What's next?","anchor":"#whats-next"},{"depth":3,"value":"I am building a subscriber product","anchor":"#i-am-building-a-subscriber-product"},{"depth":3,"value":"I am building an operator product","anchor":"#i-am-building-an-operator-product"},{"depth":2,"value":"Summary","anchor":"#summary"}],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[{"file":"examples/go/events/main.go","content":"package main\n\nimport (\n\t\"context\"\n\t\"fmt\"\n\t\"io\"\n\t\"os\"\n\t\"time\"\n\n\t\"github.com/google/uuid\"\n\t\"golang.org/x/oauth2/clientcredentials\"\n\t\"google.golang.org/grpc\"\n\t\"google.golang.org/grpc/credentials\"\n\t\"google.golang.org/grpc/credentials/oauth\"\n\t\"google.golang.org/grpc/status\"\n\t\"google.golang.org/protobuf/encoding/protojson\"\n\t\"google.golang.org/protobuf/types/known/durationpb\"\n\n\twgtwoEvents \"github.com/working-group-two/wgtwoapis/wgtwo/events/v0\"\n)\n\nfunc main() {\n\tclientCredentialsConfig := &clientcredentials.Config{\n\t\tClientID: os.Getenv(\"CLIENT_ID\"),\n\t\tClientSecret: os.Getenv(\"CLIENT_SECRET\"),\n\t\tScopes: []string{\n\t\t\t\"events.sms.subscribe\",\n\t\t},\n\t\tTokenURL: \"https://id.wgtwo.com/oauth2/token\",\n\t}\n\n\tconn, err := grpc.Dial(\n\t\t\"api.wgtwo.com:443\",\n\t\tgrpc.WithTransportCredentials(credentials.NewClientTLSFromCert(nil, \"\")),\n\t\tgrpc.WithPerRPCCredentials(\n\t\t\toauth.TokenSource{\n\t\t\t\tTokenSource: clientCredentialsConfig.TokenSource(context.Background()),\n\t\t\t},\n\t\t),\n\t)\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\tdefer conn.Close()\n\n\tclient := wgtwoEvents.NewEventsServiceClient(conn)\n\trequest := &wgtwoEvents.SubscribeEventsRequest{\n\t\tType: []wgtwoEvents.EventType{wgtwoEvents.EventType_SMS_EVENT},\n\t\tStartPosition: &wgtwoEvents.SubscribeEventsRequest_StartAtOldestPossible{},\n\t\tClientId: uuid.New().String(),\n\t\tQueueName: \"test\",\n\t\tDurableName: \"test\",\n\t\tMaxInFlight: 10,\n\t\tManualAck: &wgtwoEvents.ManualAckConfig{\n\t\t\tEnable: true,\n\t\t\tTimeout: durationpb.New(10 * time.Second),\n\t\t},\n\t}\n\n\tstream, err := client.Subscribe(context.TODO(), request)\n\n\tif err != nil || stream == nil {\n\t\tfmt.Println(\"Could not create stream. Invalid credentials perhaps?\")\n\t\treturn\n\t}\n\n\tfor {\n\t\tfmt.Println(\"Starting stream...\")\n\t\tresponse, err := stream.Recv()\n\t\tif err == io.EOF {\n\t\t\tbreak\n\t\t} else if err != nil {\n\t\t\terrStatus, _ := status.FromError(err)\n\t\t\tfmt.Printf(\"Could not get response: %s\\n\", errStatus.Code())\n\t\t\tbreak\n\t\t}\n\t\tdisplayEvent(response)\n\t\tack(client, response.Event)\n\n\t}\n}\n\nfunc displayEvent(response *wgtwoEvents.SubscribeEventsResponse) {\n\tjson, err := protojson.Marshal(response)\n\tif err != nil {\n\t\tfmt.Println(\"Could not parse response\")\n\t} else {\n\t\tfmt.Println(string(json))\n\t}\n}\n\nfunc ack(client wgtwoEvents.EventsServiceClient, event *wgtwoEvents.Event) {\n\tackCtx, cancel := context.WithTimeout(context.Background(), time.Second*10)\n\tdefer cancel()\n\t_, err := client.Ack(ackCtx, &wgtwoEvents.AckRequest{Inbox: event.Metadata.AckInbox, Sequence: event.Metadata.Sequence})\n\tif err != nil {\n\t\tfmt.Println(\"Could not ack message...\")\n\t}\n}\n"}]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Get started","headings":[{"value":"Get started"}],"subtitles":[{"depth":1,"value":"Get started","anchor":"#get-started"},{"depth":2,"value":"Download proto descriptions","anchor":"#download-proto-descriptions"},{"depth":2,"value":"Set up gRPCurl","anchor":"#set-up-grpcurl"},{"depth":2,"value":"Sandbox environment","anchor":"#sandbox-environment"},{"depth":3,"value":"Setup event streaming","anchor":"#setup-event-streaming"},{"depth":3,"value":"Explore the API","anchor":"#explore-the-api"},{"depth":2,"value":"Production environment","anchor":"#production-environment"},{"depth":3,"value":"Create OAuth 2.0 client","anchor":"#create-oauth-20-client"},{"depth":3,"value":"Get access token (using the Client Credentials Flow)","anchor":"#get-access-token-using-the-client-credentials-flow"},{"depth":3,"value":"Setup stream listening for events","anchor":"#setup-stream-listening-for-events"},{"depth":4,"value":"Example code for Go","anchor":"#example-code-for-go"},{"depth":5,"value":"Download and run code example","anchor":"#download-and-run-code-example"},{"depth":2,"value":"What's next?","anchor":"#whats-next"},{"depth":3,"value":"I am building a subscriber product","anchor":"#i-am-building-a-subscriber-product"},{"depth":3,"value":"I am building an operator product","anchor":"#i-am-building-an-operator-product"},{"depth":2,"value":"Summary","anchor":"#summary"}],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[{"file":"examples/go/events/main.go","content":"package main\n\nimport (\n\t\"context\"\n\t\"fmt\"\n\t\"io\"\n\t\"os\"\n\t\"time\"\n\n\t\"github.com/google/uuid\"\n\t\"golang.org/x/oauth2/clientcredentials\"\n\t\"google.golang.org/grpc\"\n\t\"google.golang.org/grpc/credentials\"\n\t\"google.golang.org/grpc/credentials/oauth\"\n\t\"google.golang.org/grpc/status\"\n\t\"google.golang.org/protobuf/encoding/protojson\"\n\t\"google.golang.org/protobuf/types/known/durationpb\"\n\n\twgtwoEvents \"github.com/working-group-two/wgtwoapis/wgtwo/events/v0\"\n)\n\nfunc main() {\n\tclientCredentialsConfig := &clientcredentials.Config{\n\t\tClientID: os.Getenv(\"CLIENT_ID\"),\n\t\tClientSecret: os.Getenv(\"CLIENT_SECRET\"),\n\t\tScopes: []string{\n\t\t\t\"events.sms.subscribe\",\n\t\t},\n\t\tTokenURL: \"https://id.wgtwo.com/oauth2/token\",\n\t}\n\n\tconn, err := grpc.Dial(\n\t\t\"api.wgtwo.com:443\",\n\t\tgrpc.WithTransportCredentials(credentials.NewClientTLSFromCert(nil, \"\")),\n\t\tgrpc.WithPerRPCCredentials(\n\t\t\toauth.TokenSource{\n\t\t\t\tTokenSource: clientCredentialsConfig.TokenSource(context.Background()),\n\t\t\t},\n\t\t),\n\t)\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\tdefer conn.Close()\n\n\tclient := wgtwoEvents.NewEventsServiceClient(conn)\n\trequest := &wgtwoEvents.SubscribeEventsRequest{\n\t\tType: []wgtwoEvents.EventType{wgtwoEvents.EventType_SMS_EVENT},\n\t\tStartPosition: &wgtwoEvents.SubscribeEventsRequest_StartAtOldestPossible{},\n\t\tClientId: uuid.New().String(),\n\t\tQueueName: \"test\",\n\t\tDurableName: \"test\",\n\t\tMaxInFlight: 10,\n\t\tManualAck: &wgtwoEvents.ManualAckConfig{\n\t\t\tEnable: true,\n\t\t\tTimeout: durationpb.New(10 * time.Second),\n\t\t},\n\t}\n\n\tstream, err := client.Subscribe(context.TODO(), request)\n\n\tif err != nil || stream == nil {\n\t\tfmt.Println(\"Could not create stream. Invalid credentials perhaps?\")\n\t\treturn\n\t}\n\n\tfor {\n\t\tfmt.Println(\"Starting stream...\")\n\t\tresponse, err := stream.Recv()\n\t\tif err == io.EOF {\n\t\t\tbreak\n\t\t} else if err != nil {\n\t\t\terrStatus, _ := status.FromError(err)\n\t\t\tfmt.Printf(\"Could not get response: %s\\n\", errStatus.Code())\n\t\t\tbreak\n\t\t}\n\t\tdisplayEvent(response)\n\t\tack(client, response.Event)\n\n\t}\n}\n\nfunc displayEvent(response *wgtwoEvents.SubscribeEventsResponse) {\n\tjson, err := protojson.Marshal(response)\n\tif err != nil {\n\t\tfmt.Println(\"Could not parse response\")\n\t} else {\n\t\tfmt.Println(string(json))\n\t}\n}\n\nfunc ack(client wgtwoEvents.EventsServiceClient, event *wgtwoEvents.Event) {\n\tackCtx, cancel := context.WithTimeout(context.Background(), time.Second*10)\n\tdefer cancel()\n\t_, err := client.Ack(ackCtx, &wgtwoEvents.AckRequest{Inbox: event.Metadata.AckInbox, Sequence: event.Metadata.Sequence})\n\tif err != nil {\n\t\tfmt.Println(\"Could not ack message...\")\n\t}\n}\n"}]}},"context":{}} \ No newline at end of file diff --git a/assets/data/intro/sandbox-environment/index.json b/assets/data/intro/sandbox-environment/index.json index 7b3ad5c0..0309e76f 100644 --- a/assets/data/intro/sandbox-environment/index.json +++ b/assets/data/intro/sandbox-environment/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Sandbox Environment","headings":[{"value":"Sandbox Environment"}],"subtitles":[{"depth":1,"value":"Sandbox Environment","anchor":"#sandbox-environment"},{"depth":2,"value":"Authorization","anchor":"#authorization"},{"depth":2,"value":"Customization","anchor":"#customization"},{"depth":2,"value":"Notes about the event API","anchor":"#notes-about-the-event-api"}],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Sandbox Environment","headings":[{"value":"Sandbox Environment"}],"subtitles":[{"depth":1,"value":"Sandbox Environment","anchor":"#sandbox-environment"},{"depth":2,"value":"Authorization","anchor":"#authorization"},{"depth":2,"value":"Customization","anchor":"#customization"},{"depth":2,"value":"Notes about the event API","anchor":"#notes-about-the-event-api"}],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/data/metrics/accessing-metrics/index.json b/assets/data/metrics/accessing-metrics/index.json index da160801..fe4022c2 100644 --- a/assets/data/metrics/accessing-metrics/index.json +++ b/assets/data/metrics/accessing-metrics/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Accessing Metrics","headings":[{"value":"Accessing Metrics"}],"subtitles":[{"depth":1,"value":"Accessing Metrics","anchor":"#accessing-metrics"},{"depth":2,"value":"Overview","anchor":"#overview"},{"depth":2,"value":"Credentials","anchor":"#credentials"},{"depth":2,"value":"Get metrics, curl","anchor":"#get-metrics-curl"},{"depth":2,"value":"Get metrics, Prometheus","anchor":"#get-metrics-prometheus"},{"depth":3,"value":"Example: Run with Docker","anchor":"#example-run-with-docker"},{"depth":2,"value":"Grafana","anchor":"#grafana"},{"depth":2,"value":"Links","anchor":"#links"}],"roles":[],"hideWarning":null,"sourceExamples":[{"file":"examples/config/operator/metrics/prometheus.yml","content":"global:\n scrape_interval: 30s\n evaluation_interval: 30s\n\nscrape_configs:\n - job_name: cisco\n\n metrics_path: /metrics/v1\n\n scheme: https\n oauth2:\n client_id: \"CLIENT_ID\"\n client_secret: \"CLIENT_SECRET\"\n scopes:\n - metrics.read\n token_url: \"https://id.wgtwo.com/oauth2/token\"\n\n static_configs:\n - targets:\n - \"api.wgtwo.com:443\" # Dublin\n - \"api.sakura.wgtwo.com:443\" # Tokyo\n - \"api.oak.wgtwo.com:443\" # Oregon\n"}]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Accessing Metrics","headings":[{"value":"Accessing Metrics"}],"subtitles":[{"depth":1,"value":"Accessing Metrics","anchor":"#accessing-metrics"},{"depth":2,"value":"Overview","anchor":"#overview"},{"depth":2,"value":"Credentials","anchor":"#credentials"},{"depth":2,"value":"Get metrics, curl","anchor":"#get-metrics-curl"},{"depth":2,"value":"Get metrics, Prometheus","anchor":"#get-metrics-prometheus"},{"depth":3,"value":"Example: Run with Docker","anchor":"#example-run-with-docker"},{"depth":2,"value":"Grafana","anchor":"#grafana"},{"depth":2,"value":"Links","anchor":"#links"}],"roles":[],"hideWarning":null,"sourceExamples":[{"file":"examples/config/operator/metrics/prometheus.yml","content":"global:\n scrape_interval: 30s\n evaluation_interval: 30s\n\nscrape_configs:\n - job_name: cisco\n\n metrics_path: /metrics/v1\n\n scheme: https\n oauth2:\n client_id: \"CLIENT_ID\"\n client_secret: \"CLIENT_SECRET\"\n scopes:\n - metrics.read\n token_url: \"https://id.wgtwo.com/oauth2/token\"\n\n static_configs:\n - targets:\n - \"api.wgtwo.com:443\" # Dublin\n - \"api.sakura.wgtwo.com:443\" # Tokyo\n - \"api.oak.wgtwo.com:443\" # Oregon\n"}]}},"context":{}} \ No newline at end of file diff --git a/assets/data/mms/mms-api-reference/index.json b/assets/data/mms/mms-api-reference/index.json index 2564856c..6ffd891a 100644 --- a/assets/data/mms/mms-api-reference/index.json +++ b/assets/data/mms/mms-api-reference/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"MMS API reference","headings":[],"subtitles":[],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"MMS API reference","headings":[],"subtitles":[],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/data/mms/send-mms/index.json b/assets/data/mms/send-mms/index.json index b921d25a..c9770cf9 100644 --- a/assets/data/mms/send-mms/index.json +++ b/assets/data/mms/send-mms/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Send MMS","headings":[{"value":"How to send MMS"}],"subtitles":[{"depth":1,"value":"How to send MMS","anchor":"#how-to-send-mms"},{"depth":2,"value":"Overview","anchor":"#overview"},{"depth":3,"value":"Limitations on mms.send.to_subscriber","anchor":"#limitations-on-mmssendto_subscriber"},{"depth":2,"value":"Send audio MMS","anchor":"#send-audio-mms"},{"depth":2,"value":"Concepts","anchor":"#concepts"}],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[{"file":"examples/kotlin/thirdpartydev/mms/src/main/kotlin/com/wgtwo/examples/thirdpartydev/mms/SendAudioToSubscriber.kt","content":"package com.wgtwo.examples.thirdpartydev.mms\n\nimport com.google.protobuf.ByteString\nimport com.wgtwo.api.common.Environment\nimport com.wgtwo.api.v0.common.PhoneNumberProto\nimport com.wgtwo.api.v0.mms.MmsProto\nimport com.wgtwo.api.v0.mms.MmsServiceGrpc\nimport com.wgtwo.api.util.auth.Channels\nimport com.wgtwo.api.util.auth.BearerToken\n\nprivate val credentials = BearerToken { \"MY_ACCESS_TOKEN\" } // Add your credentials\nprivate val phoneNumber = \"+47xxxxxxxx\" // Target your desired user\n\nprivate val channel = Channels.createChannel(Environment.PRODUCTION)\nprivate val stub = MmsServiceGrpc.newBlockingStub(channel).withCallCredentials(credentials)\n\nfun main() {\n val message = with(MmsProto.SendMessageToSubscriberRequest.newBuilder()) {\n val audioContent = with(MmsProto.AudioContent.newBuilder()) {\n this.wav = ByteString.readFrom(\n this::class.java.classLoader.getResource(\"test.wav\")\n .openStream()\n )\n build()\n }\n addMessageContent(MmsProto.MessageContent.newBuilder().setAudio(audioContent))\n this.fromTextAddress = with(PhoneNumberProto.TextAddress.newBuilder()) {\n this.textAddress = \"Test\"\n build()\n }\n this.toSubscriber = with(PhoneNumberProto.PhoneNumber.newBuilder()) {\n this.e164 = phoneNumber\n build()\n }\n build()\n }\n\n val result = stub.sendMessageToSubscriber(message)\n if (result.status == MmsProto.SendResponse.SendStatus.SEND_OK) {\n println(\"Successfully sent message.\")\n } else {\n println(\n \"\"\"\n Failure to send message:\n request ID= ${result.requestId}\n status=${result.status}\n description=${result.description}\"\n \"\"\".trimIndent()\n )\n }\n}\n"}]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Send MMS","headings":[{"value":"How to send MMS"}],"subtitles":[{"depth":1,"value":"How to send MMS","anchor":"#how-to-send-mms"},{"depth":2,"value":"Overview","anchor":"#overview"},{"depth":3,"value":"Limitations on mms.send.to_subscriber","anchor":"#limitations-on-mmssendto_subscriber"},{"depth":2,"value":"Send audio MMS","anchor":"#send-audio-mms"},{"depth":2,"value":"Concepts","anchor":"#concepts"}],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[{"file":"examples/kotlin/thirdpartydev/mms/src/main/kotlin/com/wgtwo/examples/thirdpartydev/mms/SendAudioToSubscriber.kt","content":"package com.wgtwo.examples.thirdpartydev.mms\n\nimport com.google.protobuf.ByteString\nimport com.wgtwo.api.common.Environment\nimport com.wgtwo.api.v0.common.PhoneNumberProto\nimport com.wgtwo.api.v0.mms.MmsProto\nimport com.wgtwo.api.v0.mms.MmsServiceGrpc\nimport com.wgtwo.api.util.auth.Channels\nimport com.wgtwo.api.util.auth.BearerToken\n\nprivate val credentials = BearerToken { \"MY_ACCESS_TOKEN\" } // Add your credentials\nprivate val phoneNumber = \"+47xxxxxxxx\" // Target your desired user\n\nprivate val channel = Channels.createChannel(Environment.PRODUCTION)\nprivate val stub = MmsServiceGrpc.newBlockingStub(channel).withCallCredentials(credentials)\n\nfun main() {\n val message = with(MmsProto.SendMessageToSubscriberRequest.newBuilder()) {\n val audioContent = with(MmsProto.AudioContent.newBuilder()) {\n this.wav = ByteString.readFrom(\n this::class.java.classLoader.getResource(\"test.wav\")\n .openStream()\n )\n build()\n }\n addMessageContent(MmsProto.MessageContent.newBuilder().setAudio(audioContent))\n this.fromTextAddress = with(PhoneNumberProto.TextAddress.newBuilder()) {\n this.textAddress = \"Test\"\n build()\n }\n this.toSubscriber = with(PhoneNumberProto.PhoneNumber.newBuilder()) {\n this.e164 = phoneNumber\n build()\n }\n build()\n }\n\n val result = stub.sendMessageToSubscriber(message)\n if (result.status == MmsProto.SendResponse.SendStatus.SEND_OK) {\n println(\"Successfully sent message.\")\n } else {\n println(\n \"\"\"\n Failure to send message:\n request ID= ${result.requestId}\n status=${result.status}\n description=${result.description}\"\n \"\"\".trimIndent()\n )\n }\n}\n"}]}},"context":{}} \ No newline at end of file diff --git a/assets/data/network-information/get-subscriber-network-information/index.json b/assets/data/network-information/get-subscriber-network-information/index.json index fcd0ad68..7d7fb8f5 100644 --- a/assets/data/network-information/get-subscriber-network-information/index.json +++ b/assets/data/network-information/get-subscriber-network-information/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Get subscriber network information","headings":[{"value":"Get subscriber network information"}],"subtitles":[{"depth":1,"value":"Get subscriber network information","anchor":"#get-subscriber-network-information"},{"depth":2,"value":"GetNetworkInfoForSubscriber","anchor":"#getnetworkinfoforsubscriber"},{"depth":2,"value":"Messages","anchor":"#messages"},{"depth":2,"value":"GetNetworkInfoForSubscriber","anchor":"#getnetworkinfoforsubscriber-1"},{"depth":2,"value":"gRPC errors","anchor":"#grpc-errors"},{"depth":3,"value":"GetNetworkInfoForSubscriber gRPC sample","anchor":"#getnetworkinfoforsubscriber-grpc-sample"},{"depth":4,"value":"GetNetworkInfoForSubscriber result","anchor":"#getnetworkinfoforsubscriber-result"},{"depth":2,"value":"GetAttachmentAttemptsForSubscriber","anchor":"#getattachmentattemptsforsubscriber"},{"depth":3,"value":"GetAttachmentAttemptsForSubscriber gRPC sample","anchor":"#getattachmentattemptsforsubscriber-grpc-sample"},{"depth":4,"value":"GetAttachmentAttemptsForSubscriber gRPC result","anchor":"#getattachmentattemptsforsubscriber-grpc-result"}],"roles":["OPERATOR"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Get subscriber network information","headings":[{"value":"Get subscriber network information"}],"subtitles":[{"depth":1,"value":"Get subscriber network information","anchor":"#get-subscriber-network-information"},{"depth":2,"value":"GetNetworkInfoForSubscriber","anchor":"#getnetworkinfoforsubscriber"},{"depth":2,"value":"Messages","anchor":"#messages"},{"depth":2,"value":"GetNetworkInfoForSubscriber","anchor":"#getnetworkinfoforsubscriber-1"},{"depth":2,"value":"gRPC errors","anchor":"#grpc-errors"},{"depth":3,"value":"GetNetworkInfoForSubscriber gRPC sample","anchor":"#getnetworkinfoforsubscriber-grpc-sample"},{"depth":4,"value":"GetNetworkInfoForSubscriber result","anchor":"#getnetworkinfoforsubscriber-result"},{"depth":2,"value":"GetAttachmentAttemptsForSubscriber","anchor":"#getattachmentattemptsforsubscriber"},{"depth":3,"value":"GetAttachmentAttemptsForSubscriber gRPC sample","anchor":"#getattachmentattemptsforsubscriber-grpc-sample"},{"depth":4,"value":"GetAttachmentAttemptsForSubscriber gRPC result","anchor":"#getattachmentattemptsforsubscriber-grpc-result"}],"roles":["OPERATOR"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/data/network-information/network-info-api/index.json b/assets/data/network-information/network-info-api/index.json index 79fdb00c..dc50f830 100644 --- a/assets/data/network-information/network-info-api/index.json +++ b/assets/data/network-information/network-info-api/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Network info API","headings":[],"subtitles":[],"roles":["OPERATOR"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Network info API","headings":[],"subtitles":[],"roles":["OPERATOR"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/data/number-lookup/api-reference/index.json b/assets/data/number-lookup/api-reference/index.json index be182acb..a7658e8d 100644 --- a/assets/data/number-lookup/api-reference/index.json +++ b/assets/data/number-lookup/api-reference/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"API reference","headings":[],"subtitles":[],"roles":["THIRD_PARTY_DEVELOPER"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"API reference","headings":[],"subtitles":[],"roles":["THIRD_PARTY_DEVELOPER"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/data/number-lookup/overview/index.json b/assets/data/number-lookup/overview/index.json index ac94007a..c42ae230 100644 --- a/assets/data/number-lookup/overview/index.json +++ b/assets/data/number-lookup/overview/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Overview","headings":[{"value":"Number Lookup API"}],"subtitles":[{"depth":1,"value":"Number Lookup API","anchor":"#number-lookup-api"},{"depth":2,"value":"Intended audience","anchor":"#intended-audience"},{"depth":2,"value":"Usage","anchor":"#usage"},{"depth":2,"value":"Include display name as part of call setup","anchor":"#include-display-name-as-part-of-call-setup"},{"depth":3,"value":"Get number information from provider","anchor":"#get-number-information-from-provider"},{"depth":3,"value":"Show display name","anchor":"#show-display-name"},{"depth":2,"value":"Error handling","anchor":"#error-handling"},{"depth":2,"value":"Continue reading","anchor":"#continue-reading"}],"roles":["THIRD_PARTY_DEVELOPER"],"hideWarning":null,"sourceExamples":[{"file":"examples/kotlin/thirdpartydev/number-lookup/src/main/kotlin/com/wgtwo/examples/thirdpartydev/provider/Provider.kt","content":"package com.wgtwo.examples.thirdpartydev.numberlookup\n\nimport com.google.protobuf.util.Durations\nimport com.wgtwo.api.v0.lookup.NumberLookupProto.NumberLookupRequest\nimport com.wgtwo.api.v0.lookup.NumberLookupProto.NumberLookupResponse\nimport com.wgtwo.api.v0.lookup.NumberLookupServiceGrpcKt\nimport com.wgtwo.api.v0.lookup.cacheControl\nimport com.wgtwo.api.v0.lookup.numberLookupResponse\nimport com.wgtwo.api.v0.lookup.result\nimport com.wgtwo.auth.BearerTokenCallCredentials\nimport io.grpc.ManagedChannelBuilder\nimport kotlinx.coroutines.channels.Channel\nimport kotlinx.coroutines.delay\nimport kotlinx.coroutines.flow.catch\nimport kotlinx.coroutines.flow.collect\nimport kotlinx.coroutines.flow.flow\nimport kotlinx.coroutines.flow.onEach\nimport kotlinx.coroutines.flow.onStart\nimport kotlinx.coroutines.runBlocking\nimport java.util.concurrent.TimeUnit\nimport kotlin.time.Duration.Companion.seconds\n\nprivate val grpcChannel = ManagedChannelBuilder.forTarget(\"api.wgtwo.com:443\")\n .keepAliveWithoutCalls(true)\n .keepAliveTime(1, TimeUnit.MINUTES)\n .keepAliveTimeout(10, TimeUnit.SECONDS)\n .idleTimeout(1, TimeUnit.HOURS)\n .build()\n\nprivate val stub = NumberLookupServiceGrpcKt.NumberLookupServiceCoroutineStub(grpcChannel)\n .withCallCredentials(BearerTokenCallCredentials { \"MY ACCESS TOKEN\" })\n\nval phonebook = mapOf(\n \"+4799999999\" to \"John Doe\",\n)\n\nsuspend fun startStream() {\n val responseQueue = Channel()\n\n // Check queue to see if we have any responses and send them over the wire\n val responseFlow = flow {\n for (response in responseQueue) {\n emit(response)\n }\n }\n stub.numberLookup(responseFlow)\n .onStart { println(\"Starting new stream\") }\n .onEach { request: NumberLookupRequest ->\n println(\"Got request for ${request.number.e164}\")\n val displayName = phonebook.getOrDefault(request.number.e164, \"\")\n val response = numberLookupResponse {\n numberLookupRequest = request\n result = result {\n name = displayName\n }\n cacheControl = cacheControl {\n maxAge = Durations.fromMinutes(60)\n }\n }\n println(\"Sending response for ${response.numberLookupRequest.number.e164}: ${response.result.name}\")\n responseQueue.send(response)\n }\n .catch { e ->\n println(\"Got error: ${e.message} - Will reconnect in 1s\")\n delay(1.seconds)\n }\n .collect()\n}\n\nfun main() = runBlocking {\n // Run forever - if the stream fails we will reconnect\n while (true) {\n startStream()\n }\n}\n"}]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Overview","headings":[{"value":"Number Lookup API"}],"subtitles":[{"depth":1,"value":"Number Lookup API","anchor":"#number-lookup-api"},{"depth":2,"value":"Intended audience","anchor":"#intended-audience"},{"depth":2,"value":"Usage","anchor":"#usage"},{"depth":2,"value":"Include display name as part of call setup","anchor":"#include-display-name-as-part-of-call-setup"},{"depth":3,"value":"Get number information from provider","anchor":"#get-number-information-from-provider"},{"depth":3,"value":"Show display name","anchor":"#show-display-name"},{"depth":2,"value":"Error handling","anchor":"#error-handling"},{"depth":2,"value":"Continue reading","anchor":"#continue-reading"}],"roles":["THIRD_PARTY_DEVELOPER"],"hideWarning":null,"sourceExamples":[{"file":"examples/kotlin/thirdpartydev/number-lookup/src/main/kotlin/com/wgtwo/examples/thirdpartydev/provider/Provider.kt","content":"package com.wgtwo.examples.thirdpartydev.numberlookup\n\nimport com.google.protobuf.util.Durations\nimport com.wgtwo.api.v0.lookup.NumberLookupProto.NumberLookupRequest\nimport com.wgtwo.api.v0.lookup.NumberLookupProto.NumberLookupResponse\nimport com.wgtwo.api.v0.lookup.NumberLookupServiceGrpcKt\nimport com.wgtwo.api.v0.lookup.cacheControl\nimport com.wgtwo.api.v0.lookup.numberLookupResponse\nimport com.wgtwo.api.v0.lookup.result\nimport com.wgtwo.auth.BearerTokenCallCredentials\nimport io.grpc.ManagedChannelBuilder\nimport kotlinx.coroutines.channels.Channel\nimport kotlinx.coroutines.delay\nimport kotlinx.coroutines.flow.catch\nimport kotlinx.coroutines.flow.collect\nimport kotlinx.coroutines.flow.flow\nimport kotlinx.coroutines.flow.onEach\nimport kotlinx.coroutines.flow.onStart\nimport kotlinx.coroutines.runBlocking\nimport java.util.concurrent.TimeUnit\nimport kotlin.time.Duration.Companion.seconds\n\nprivate val grpcChannel = ManagedChannelBuilder.forTarget(\"api.wgtwo.com:443\")\n .keepAliveWithoutCalls(true)\n .keepAliveTime(1, TimeUnit.MINUTES)\n .keepAliveTimeout(10, TimeUnit.SECONDS)\n .idleTimeout(1, TimeUnit.HOURS)\n .build()\n\nprivate val stub = NumberLookupServiceGrpcKt.NumberLookupServiceCoroutineStub(grpcChannel)\n .withCallCredentials(BearerTokenCallCredentials { \"MY ACCESS TOKEN\" })\n\nval phonebook = mapOf(\n \"+4799999999\" to \"John Doe\",\n)\n\nsuspend fun startStream() {\n val responseQueue = Channel()\n\n // Check queue to see if we have any responses and send them over the wire\n val responseFlow = flow {\n for (response in responseQueue) {\n emit(response)\n }\n }\n stub.numberLookup(responseFlow)\n .onStart { println(\"Starting new stream\") }\n .onEach { request: NumberLookupRequest ->\n println(\"Got request for ${request.number.e164}\")\n val displayName = phonebook.getOrDefault(request.number.e164, \"\")\n val response = numberLookupResponse {\n numberLookupRequest = request\n result = result {\n name = displayName\n }\n cacheControl = cacheControl {\n maxAge = Durations.fromMinutes(60)\n }\n }\n println(\"Sending response for ${response.numberLookupRequest.number.e164}: ${response.result.name}\")\n responseQueue.send(response)\n }\n .catch { e ->\n println(\"Got error: ${e.message} - Will reconnect in 1s\")\n delay(1.seconds)\n }\n .collect()\n}\n\nfun main() = runBlocking {\n // Run forever - if the stream fails we will reconnect\n while (true) {\n startStream()\n }\n}\n"}]}},"context":{}} \ No newline at end of file diff --git a/assets/data/number-lookup/technical-guide/index.json b/assets/data/number-lookup/technical-guide/index.json index 51f4d586..cc227122 100644 --- a/assets/data/number-lookup/technical-guide/index.json +++ b/assets/data/number-lookup/technical-guide/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Technical guide","headings":[{"value":"Number Lookup API - Technical Guide"}],"subtitles":[{"depth":1,"value":"Number Lookup API - Technical Guide","anchor":"#number-lookup-api---technical-guide"},{"depth":2,"value":"Prerequisites","anchor":"#prerequisites"},{"depth":3,"value":"Required scope","anchor":"#required-scope"},{"depth":2,"value":"How to use the API","anchor":"#how-to-use-the-api"},{"depth":2,"value":"Flow","anchor":"#flow"},{"depth":2,"value":"Request / Response","anchor":"#request--response"},{"depth":3,"value":"Request","anchor":"#request"},{"depth":3,"value":"Response","anchor":"#response"},{"depth":3,"value":"Response, upstream error","anchor":"#response-upstream-error"},{"depth":2,"value":"Limitations for display name","anchor":"#limitations-for-display-name"},{"depth":2,"value":"Error handling","anchor":"#error-handling"},{"depth":2,"value":"Cache","anchor":"#cache"},{"depth":2,"value":"Recommended gRPC connection settings","anchor":"#recommended-grpc-connection-settings"},{"depth":3,"value":"Keep-Alive","anchor":"#keep-alive"},{"depth":2,"value":"Local testing","anchor":"#local-testing"},{"depth":3,"value":"Docker","anchor":"#docker"},{"depth":2,"value":"Continue reading","anchor":"#continue-reading"},{"depth":2,"value":"Concepts","anchor":"#concepts"}],"roles":["THIRD_PARTY_DEVELOPER"],"hideWarning":null,"sourceExamples":[{"file":"examples/grpcurl/thirdpartydev/number-lookup/provider.sh","content":"#!/usr/bin/env bash\n\n# Download the API definition\ncurl -sL 'https://github.com/working-group-two/wgtwoapis/blob/master/image.bin?raw=true' -o proto/wgtwo.bin\n\n# Access token must be obtained via the client credentials flow\nACCESS_TOKEN=$(\n curl -s -u $CLIENT_ID:$CLIENT_SECRET \\\n --request POST \\\n --url 'https://id.wgtwo.com/oauth2/token' \\\n --header 'content-type: application/x-www-form-urlencoded' \\\n --data grant_type=\"client_credentials\" \\\n --data scope=\"lookup.number:read\" \\\n | jq -r .access_token\n)\n\n# We send data to grpcurl via a PIPE, and receive data via stdout.\nPIPE=/tmp/provider-PIPE\nmkfifo $PIPE\nexec 3<> $PIPE\n\ncleanup() {\n echo \"Cleaning up...\"\n rm -f $PIPE\n exec 3>&-\n exit\n}\ntrap cleanup INT TERM EXIT\n\ngrpcurl \\\n -H \"Authorization: Bearer $ACCESS_TOKEN\" \\\n -protoset wgtwo.bin \\\n -d @ \\\n api.wgtwo.com:443 \\\n wgtwo.lookup.v0.NumberLookupService/NumberLookup <&3 \\\n| while IFS= read -r LINE; do\n # grpcurl sends output line by line, so we buffer until we have a valid JSON object.\n BUFFER+=\"$LINE\"\n if ! jq . >/dev/null 2>&1 <<<\"$BUFFER\"; then continue; fi\n\n # Create a JSON response that includes the request and a dummy result.\n RESPONSE_JSON=$(jq -c -n --argjson incoming_content \"$BUFFER\" \\\n '{\n number_lookup_request: $incoming_content,\n result: {\n name: \"John Doe\"\n }\n }'\n )\n\n # Send the response to grpcurl via the PIPE.\n echo \"$RESPONSE_JSON\" > $PIPE\n\n echo \"Sent response:\"\n echo \"$RESPONSE_JSON\" | jq .\n echo \"\"\n\n # Clear the buffer.\n BUFFER=\"\"\ndone\n"},{"file":"examples/kotlin/thirdpartydev/number-lookup/src/main/kotlin/com/wgtwo/examples/thirdpartydev/provider/Provider.kt","content":"package com.wgtwo.examples.thirdpartydev.numberlookup\n\nimport com.google.protobuf.util.Durations\nimport com.wgtwo.api.v0.lookup.NumberLookupProto.NumberLookupRequest\nimport com.wgtwo.api.v0.lookup.NumberLookupProto.NumberLookupResponse\nimport com.wgtwo.api.v0.lookup.NumberLookupServiceGrpcKt\nimport com.wgtwo.api.v0.lookup.cacheControl\nimport com.wgtwo.api.v0.lookup.numberLookupResponse\nimport com.wgtwo.api.v0.lookup.result\nimport com.wgtwo.auth.BearerTokenCallCredentials\nimport io.grpc.ManagedChannelBuilder\nimport kotlinx.coroutines.channels.Channel\nimport kotlinx.coroutines.delay\nimport kotlinx.coroutines.flow.catch\nimport kotlinx.coroutines.flow.collect\nimport kotlinx.coroutines.flow.flow\nimport kotlinx.coroutines.flow.onEach\nimport kotlinx.coroutines.flow.onStart\nimport kotlinx.coroutines.runBlocking\nimport java.util.concurrent.TimeUnit\nimport kotlin.time.Duration.Companion.seconds\n\nprivate val grpcChannel = ManagedChannelBuilder.forTarget(\"api.wgtwo.com:443\")\n .keepAliveWithoutCalls(true)\n .keepAliveTime(1, TimeUnit.MINUTES)\n .keepAliveTimeout(10, TimeUnit.SECONDS)\n .idleTimeout(1, TimeUnit.HOURS)\n .build()\n\nprivate val stub = NumberLookupServiceGrpcKt.NumberLookupServiceCoroutineStub(grpcChannel)\n .withCallCredentials(BearerTokenCallCredentials { \"MY ACCESS TOKEN\" })\n\nval phonebook = mapOf(\n \"+4799999999\" to \"John Doe\",\n)\n\nsuspend fun startStream() {\n val responseQueue = Channel()\n\n // Check queue to see if we have any responses and send them over the wire\n val responseFlow = flow {\n for (response in responseQueue) {\n emit(response)\n }\n }\n stub.numberLookup(responseFlow)\n .onStart { println(\"Starting new stream\") }\n .onEach { request: NumberLookupRequest ->\n println(\"Got request for ${request.number.e164}\")\n val displayName = phonebook.getOrDefault(request.number.e164, \"\")\n val response = numberLookupResponse {\n numberLookupRequest = request\n result = result {\n name = displayName\n }\n cacheControl = cacheControl {\n maxAge = Durations.fromMinutes(60)\n }\n }\n println(\"Sending response for ${response.numberLookupRequest.number.e164}: ${response.result.name}\")\n responseQueue.send(response)\n }\n .catch { e ->\n println(\"Got error: ${e.message} - Will reconnect in 1s\")\n delay(1.seconds)\n }\n .collect()\n}\n\nfun main() = runBlocking {\n // Run forever - if the stream fails we will reconnect\n while (true) {\n startStream()\n }\n}\n"}]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Technical guide","headings":[{"value":"Number Lookup API - Technical Guide"}],"subtitles":[{"depth":1,"value":"Number Lookup API - Technical Guide","anchor":"#number-lookup-api---technical-guide"},{"depth":2,"value":"Prerequisites","anchor":"#prerequisites"},{"depth":3,"value":"Required scope","anchor":"#required-scope"},{"depth":2,"value":"How to use the API","anchor":"#how-to-use-the-api"},{"depth":2,"value":"Flow","anchor":"#flow"},{"depth":2,"value":"Request / Response","anchor":"#request--response"},{"depth":3,"value":"Request","anchor":"#request"},{"depth":3,"value":"Response","anchor":"#response"},{"depth":3,"value":"Response, upstream error","anchor":"#response-upstream-error"},{"depth":2,"value":"Limitations for display name","anchor":"#limitations-for-display-name"},{"depth":2,"value":"Error handling","anchor":"#error-handling"},{"depth":2,"value":"Cache","anchor":"#cache"},{"depth":2,"value":"Recommended gRPC connection settings","anchor":"#recommended-grpc-connection-settings"},{"depth":3,"value":"Keep-Alive","anchor":"#keep-alive"},{"depth":2,"value":"Local testing","anchor":"#local-testing"},{"depth":3,"value":"Docker","anchor":"#docker"},{"depth":2,"value":"Continue reading","anchor":"#continue-reading"},{"depth":2,"value":"Concepts","anchor":"#concepts"}],"roles":["THIRD_PARTY_DEVELOPER"],"hideWarning":null,"sourceExamples":[{"file":"examples/grpcurl/thirdpartydev/number-lookup/provider.sh","content":"#!/usr/bin/env bash\n\n# Download the API definition\ncurl -sL 'https://github.com/working-group-two/wgtwoapis/blob/master/image.bin?raw=true' -o proto/wgtwo.bin\n\n# Access token must be obtained via the client credentials flow\nACCESS_TOKEN=$(\n curl -s -u $CLIENT_ID:$CLIENT_SECRET \\\n --request POST \\\n --url 'https://id.wgtwo.com/oauth2/token' \\\n --header 'content-type: application/x-www-form-urlencoded' \\\n --data grant_type=\"client_credentials\" \\\n --data scope=\"lookup.number:read\" \\\n | jq -r .access_token\n)\n\n# We send data to grpcurl via a PIPE, and receive data via stdout.\nPIPE=/tmp/provider-PIPE\nmkfifo $PIPE\nexec 3<> $PIPE\n\ncleanup() {\n echo \"Cleaning up...\"\n rm -f $PIPE\n exec 3>&-\n exit\n}\ntrap cleanup INT TERM EXIT\n\ngrpcurl \\\n -H \"Authorization: Bearer $ACCESS_TOKEN\" \\\n -protoset wgtwo.bin \\\n -d @ \\\n api.wgtwo.com:443 \\\n wgtwo.lookup.v0.NumberLookupService/NumberLookup <&3 \\\n| while IFS= read -r LINE; do\n # grpcurl sends output line by line, so we buffer until we have a valid JSON object.\n BUFFER+=\"$LINE\"\n if ! jq . >/dev/null 2>&1 <<<\"$BUFFER\"; then continue; fi\n\n # Create a JSON response that includes the request and a dummy result.\n RESPONSE_JSON=$(jq -c -n --argjson incoming_content \"$BUFFER\" \\\n '{\n number_lookup_request: $incoming_content,\n result: {\n name: \"John Doe\"\n }\n }'\n )\n\n # Send the response to grpcurl via the PIPE.\n echo \"$RESPONSE_JSON\" > $PIPE\n\n echo \"Sent response:\"\n echo \"$RESPONSE_JSON\" | jq .\n echo \"\"\n\n # Clear the buffer.\n BUFFER=\"\"\ndone\n"},{"file":"examples/kotlin/thirdpartydev/number-lookup/src/main/kotlin/com/wgtwo/examples/thirdpartydev/provider/Provider.kt","content":"package com.wgtwo.examples.thirdpartydev.numberlookup\n\nimport com.google.protobuf.util.Durations\nimport com.wgtwo.api.v0.lookup.NumberLookupProto.NumberLookupRequest\nimport com.wgtwo.api.v0.lookup.NumberLookupProto.NumberLookupResponse\nimport com.wgtwo.api.v0.lookup.NumberLookupServiceGrpcKt\nimport com.wgtwo.api.v0.lookup.cacheControl\nimport com.wgtwo.api.v0.lookup.numberLookupResponse\nimport com.wgtwo.api.v0.lookup.result\nimport com.wgtwo.auth.BearerTokenCallCredentials\nimport io.grpc.ManagedChannelBuilder\nimport kotlinx.coroutines.channels.Channel\nimport kotlinx.coroutines.delay\nimport kotlinx.coroutines.flow.catch\nimport kotlinx.coroutines.flow.collect\nimport kotlinx.coroutines.flow.flow\nimport kotlinx.coroutines.flow.onEach\nimport kotlinx.coroutines.flow.onStart\nimport kotlinx.coroutines.runBlocking\nimport java.util.concurrent.TimeUnit\nimport kotlin.time.Duration.Companion.seconds\n\nprivate val grpcChannel = ManagedChannelBuilder.forTarget(\"api.wgtwo.com:443\")\n .keepAliveWithoutCalls(true)\n .keepAliveTime(1, TimeUnit.MINUTES)\n .keepAliveTimeout(10, TimeUnit.SECONDS)\n .idleTimeout(1, TimeUnit.HOURS)\n .build()\n\nprivate val stub = NumberLookupServiceGrpcKt.NumberLookupServiceCoroutineStub(grpcChannel)\n .withCallCredentials(BearerTokenCallCredentials { \"MY ACCESS TOKEN\" })\n\nval phonebook = mapOf(\n \"+4799999999\" to \"John Doe\",\n)\n\nsuspend fun startStream() {\n val responseQueue = Channel()\n\n // Check queue to see if we have any responses and send them over the wire\n val responseFlow = flow {\n for (response in responseQueue) {\n emit(response)\n }\n }\n stub.numberLookup(responseFlow)\n .onStart { println(\"Starting new stream\") }\n .onEach { request: NumberLookupRequest ->\n println(\"Got request for ${request.number.e164}\")\n val displayName = phonebook.getOrDefault(request.number.e164, \"\")\n val response = numberLookupResponse {\n numberLookupRequest = request\n result = result {\n name = displayName\n }\n cacheControl = cacheControl {\n maxAge = Durations.fromMinutes(60)\n }\n }\n println(\"Sending response for ${response.numberLookupRequest.number.e164}: ${response.result.name}\")\n responseQueue.send(response)\n }\n .catch { e ->\n println(\"Got error: ${e.message} - Will reconnect in 1s\")\n delay(1.seconds)\n }\n .collect()\n}\n\nfun main() = runBlocking {\n // Run forever - if the stream fails we will reconnect\n while (true) {\n startStream()\n }\n}\n"}]}},"context":{}} \ No newline at end of file diff --git a/assets/data/oauth-2-0/create-o-auth-2-0-client/index.json b/assets/data/oauth-2-0/create-o-auth-2-0-client/index.json index 649a5e0c..04aa8ac6 100644 --- a/assets/data/oauth-2-0/create-o-auth-2-0-client/index.json +++ b/assets/data/oauth-2-0/create-o-auth-2-0-client/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Create OAuth 2.0 client","headings":[{"value":"Create OAuth 2.0 client"}],"subtitles":[{"depth":1,"value":"Create OAuth 2.0 client","anchor":"#create-oauth-20-client"},{"depth":2,"value":"Create client","anchor":"#create-client"},{"depth":2,"value":"Set scopes","anchor":"#set-scopes"},{"depth":2,"value":"Enable product for operator","anchor":"#enable-product-for-operator"},{"depth":2,"value":"That's it","anchor":"#thats-it"}],"roles":["THIRD_PARTY_DEVELOPER"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Create OAuth 2.0 client","headings":[{"value":"Create OAuth 2.0 client"}],"subtitles":[{"depth":1,"value":"Create OAuth 2.0 client","anchor":"#create-oauth-20-client"},{"depth":2,"value":"Create client","anchor":"#create-client"},{"depth":2,"value":"Set scopes","anchor":"#set-scopes"},{"depth":2,"value":"Enable product for operator","anchor":"#enable-product-for-operator"},{"depth":2,"value":"That's it","anchor":"#thats-it"}],"roles":["THIRD_PARTY_DEVELOPER"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/data/oauth-2-0/get-client-access-token/index.json b/assets/data/oauth-2-0/get-client-access-token/index.json index 7e44a7a5..d5950597 100644 --- a/assets/data/oauth-2-0/get-client-access-token/index.json +++ b/assets/data/oauth-2-0/get-client-access-token/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Get client access token","headings":[{"value":"Get client access token"}],"subtitles":[{"depth":1,"value":"Get client access token","anchor":"#get-client-access-token"},{"depth":2,"value":"Prerequisites","anchor":"#prerequisites"},{"depth":2,"value":"Use a library","anchor":"#use-a-library"},{"depth":2,"value":"Resources","anchor":"#resources"}],"roles":["THIRD_PARTY_DEVELOPER"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Get client access token","headings":[{"value":"Get client access token"}],"subtitles":[{"depth":1,"value":"Get client access token","anchor":"#get-client-access-token"},{"depth":2,"value":"Prerequisites","anchor":"#prerequisites"},{"depth":2,"value":"Use a library","anchor":"#use-a-library"},{"depth":2,"value":"Resources","anchor":"#resources"}],"roles":["THIRD_PARTY_DEVELOPER"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/data/oauth-2-0/get-user-access-token/index.json b/assets/data/oauth-2-0/get-user-access-token/index.json index fc48d283..c709fe09 100644 --- a/assets/data/oauth-2-0/get-user-access-token/index.json +++ b/assets/data/oauth-2-0/get-user-access-token/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Get user access token","headings":[{"value":"Get user access token"}],"subtitles":[{"depth":1,"value":"Get user access token","anchor":"#get-user-access-token"},{"depth":2,"value":"Prerequisites","anchor":"#prerequisites"},{"depth":2,"value":"Use a library","anchor":"#use-a-library"},{"depth":2,"value":"Resources","anchor":"#resources"},{"depth":2,"value":"Manually run the OAuth flow","anchor":"#manually-run-the-oauth-flow"},{"depth":3,"value":"Open link in browser","anchor":"#open-link-in-browser"},{"depth":3,"value":"Exchange authorization code for access and refresh token","anchor":"#exchange-authorization-code-for-access-and-refresh-token"},{"depth":3,"value":"Use access token to get user info","anchor":"#use-access-token-to-get-user-info"}],"roles":["THIRD_PARTY_DEVELOPER"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Get user access token","headings":[{"value":"Get user access token"}],"subtitles":[{"depth":1,"value":"Get user access token","anchor":"#get-user-access-token"},{"depth":2,"value":"Prerequisites","anchor":"#prerequisites"},{"depth":2,"value":"Use a library","anchor":"#use-a-library"},{"depth":2,"value":"Resources","anchor":"#resources"},{"depth":2,"value":"Manually run the OAuth flow","anchor":"#manually-run-the-oauth-flow"},{"depth":3,"value":"Open link in browser","anchor":"#open-link-in-browser"},{"depth":3,"value":"Exchange authorization code for access and refresh token","anchor":"#exchange-authorization-code-for-access-and-refresh-token"},{"depth":3,"value":"Use access token to get user info","anchor":"#use-access-token-to-get-user-info"}],"roles":["THIRD_PARTY_DEVELOPER"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/data/oauth-2-0/overview/index.json b/assets/data/oauth-2-0/overview/index.json index e683ba33..cda7004f 100644 --- a/assets/data/oauth-2-0/overview/index.json +++ b/assets/data/oauth-2-0/overview/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Overview","headings":[{"value":"OAuth 2.0"}],"subtitles":[{"depth":1,"value":"OAuth 2.0","anchor":"#oauth-20"},{"depth":2,"value":"Usage","anchor":"#usage"},{"depth":2,"value":"Endpoints","anchor":"#endpoints"},{"depth":2,"value":"Grant types supported","anchor":"#grant-types-supported"},{"depth":2,"value":"Scopes","anchor":"#scopes"},{"depth":2,"value":"Subject identifier","anchor":"#subject-identifier"},{"depth":2,"value":"JSON Web Key Set","anchor":"#json-web-key-set"}],"roles":["THIRD_PARTY_DEVELOPER"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Overview","headings":[{"value":"OAuth 2.0"}],"subtitles":[{"depth":1,"value":"OAuth 2.0","anchor":"#oauth-20"},{"depth":2,"value":"Usage","anchor":"#usage"},{"depth":2,"value":"Endpoints","anchor":"#endpoints"},{"depth":2,"value":"Grant types supported","anchor":"#grant-types-supported"},{"depth":2,"value":"Scopes","anchor":"#scopes"},{"depth":2,"value":"Subject identifier","anchor":"#subject-identifier"},{"depth":2,"value":"JSON Web Key Set","anchor":"#json-web-key-set"}],"roles":["THIRD_PARTY_DEVELOPER"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/data/oauth-2-0/support-revoking-consent/index.json b/assets/data/oauth-2-0/support-revoking-consent/index.json index 80fefc31..1ec5b879 100644 --- a/assets/data/oauth-2-0/support-revoking-consent/index.json +++ b/assets/data/oauth-2-0/support-revoking-consent/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Support revoking consent","headings":[{"value":"Support revoking consent"}],"subtitles":[{"depth":1,"value":"Support revoking consent","anchor":"#support-revoking-consent"},{"depth":2,"value":"Definitions","anchor":"#definitions"},{"depth":2,"value":"Flow","anchor":"#flow"},{"depth":2,"value":"Redirect","anchor":"#redirect"},{"depth":2,"value":"Generate a revoke consent magic link","anchor":"#generate-a-revoke-consent-magic-link"},{"depth":2,"value":"Request","anchor":"#request"},{"depth":3,"value":"Response","anchor":"#response"},{"depth":2,"value":"Flow chart","anchor":"#flow-chart"}],"roles":["THIRD_PARTY_DEVELOPER"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Support revoking consent","headings":[{"value":"Support revoking consent"}],"subtitles":[{"depth":1,"value":"Support revoking consent","anchor":"#support-revoking-consent"},{"depth":2,"value":"Definitions","anchor":"#definitions"},{"depth":2,"value":"Flow","anchor":"#flow"},{"depth":2,"value":"Redirect","anchor":"#redirect"},{"depth":2,"value":"Generate a revoke consent magic link","anchor":"#generate-a-revoke-consent-magic-link"},{"depth":2,"value":"Request","anchor":"#request"},{"depth":3,"value":"Response","anchor":"#response"},{"depth":2,"value":"Flow chart","anchor":"#flow-chart"}],"roles":["THIRD_PARTY_DEVELOPER"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/data/oauth-2-0/why-support-user-revoking-of-consent/index.json b/assets/data/oauth-2-0/why-support-user-revoking-of-consent/index.json index 70b4cdf3..acec90c6 100644 --- a/assets/data/oauth-2-0/why-support-user-revoking-of-consent/index.json +++ b/assets/data/oauth-2-0/why-support-user-revoking-of-consent/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Why support user revoking of consent","headings":[{"value":"Why support user revoking of consent"}],"subtitles":[{"depth":1,"value":"Why support user revoking of consent","anchor":"#why-support-user-revoking-of-consent"},{"depth":2,"value":"Granting and revoking consent","anchor":"#granting-and-revoking-consent"}],"roles":["THIRD_PARTY_DEVELOPER"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Why support user revoking of consent","headings":[{"value":"Why support user revoking of consent"}],"subtitles":[{"depth":1,"value":"Why support user revoking of consent","anchor":"#why-support-user-revoking-of-consent"},{"depth":2,"value":"Granting and revoking consent","anchor":"#granting-and-revoking-consent"}],"roles":["THIRD_PARTY_DEVELOPER"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/data/pbx/pbx-tas-integration/index.json b/assets/data/pbx/pbx-tas-integration/index.json index 7dc5d489..cc51892a 100644 --- a/assets/data/pbx/pbx-tas-integration/index.json +++ b/assets/data/pbx/pbx-tas-integration/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"PBX/TAS integration","headings":[],"subtitles":[],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"PBX/TAS integration","headings":[],"subtitles":[],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/data/subscription-profile/manage-subscriptions/index.json b/assets/data/subscription-profile/manage-subscriptions/index.json index 55378ea7..bfaafa72 100644 --- a/assets/data/subscription-profile/manage-subscriptions/index.json +++ b/assets/data/subscription-profile/manage-subscriptions/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Manage subscriptions","headings":[],"subtitles":[],"roles":[],"hideWarning":true,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Manage subscriptions","headings":[],"subtitles":[],"roles":[],"hideWarning":true,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/data/subscription-profile/overview/index.json b/assets/data/subscription-profile/overview/index.json index 0a534fe2..d0cb82c5 100644 --- a/assets/data/subscription-profile/overview/index.json +++ b/assets/data/subscription-profile/overview/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Overview","headings":[],"subtitles":[],"roles":[],"hideWarning":true,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Overview","headings":[],"subtitles":[],"roles":[],"hideWarning":true,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/data/subscription-profile/subscription-profile-api-reference/index.json b/assets/data/subscription-profile/subscription-profile-api-reference/index.json index b75c0a41..9abe2c51 100644 --- a/assets/data/subscription-profile/subscription-profile-api-reference/index.json +++ b/assets/data/subscription-profile/subscription-profile-api-reference/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Subscription profile API reference","headings":[],"subtitles":[],"roles":[],"hideWarning":true,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Subscription profile API reference","headings":[],"subtitles":[],"roles":[],"hideWarning":true,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/data/subscription-profile/subscription-services/index.json b/assets/data/subscription-profile/subscription-services/index.json index b8b821fe..9d54fea3 100644 --- a/assets/data/subscription-profile/subscription-services/index.json +++ b/assets/data/subscription-profile/subscription-services/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Subscription services","headings":[],"subtitles":[],"roles":[],"hideWarning":true,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Subscription services","headings":[],"subtitles":[],"roles":[],"hideWarning":true,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/data/web-terminal/create-a-web-terminal-to-make-and-receive-calls/index.json b/assets/data/web-terminal/create-a-web-terminal-to-make-and-receive-calls/index.json index 26f5766d..f27e4c95 100644 --- a/assets/data/web-terminal/create-a-web-terminal-to-make-and-receive-calls/index.json +++ b/assets/data/web-terminal/create-a-web-terminal-to-make-and-receive-calls/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Create a Web Terminal to make and receive calls","headings":[{"value":"Make and receive WebRTC calls"}],"subtitles":[{"depth":1,"value":"Make and receive WebRTC calls","anchor":"#make-and-receive-webrtc-calls"},{"depth":2,"value":"Prerequisites","anchor":"#prerequisites"},{"depth":2,"value":"Overview","anchor":"#overview"},{"depth":2,"value":"The API","anchor":"#the-api"},{"depth":3,"value":"Example code","anchor":"#example-code"},{"depth":3,"value":"Common scenarios","anchor":"#common-scenarios"},{"depth":4,"value":"Initiating a call from a WebRTC terminal","anchor":"#initiating-a-call-from-a-webrtc-terminal"},{"depth":4,"value":"Receiving an incoming call from the core","anchor":"#receiving-an-incoming-call-from-the-core"},{"depth":4,"value":"Observing status","anchor":"#observing-status"},{"depth":4,"value":"Transferring call to Terminal","anchor":"#transferring-call-to-terminal"},{"depth":4,"value":"Transferring call to the mobile terminal","anchor":"#transferring-call-to-the-mobile-terminal"},{"depth":4,"value":"ICE","anchor":"#ice"},{"depth":4,"value":"Renegotiating SDP","anchor":"#renegotiating-sdp"},{"depth":2,"value":"Concepts","anchor":"#concepts"}],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[{"file":"examples/kotlin/thirdpartydev/webterminal/src/main/kotlin/com/wgtwo/examples/thirdpartydev/webterminal/InitiateCall.kt","content":"package com.wgtwo.examples.thirdpartydev.webterminal\n\nimport com.wgtwo.api.common.Environment\nimport com.wgtwo.api.v0.common.PhoneNumberProto\nimport com.wgtwo.api.util.auth.Channels\nimport com.wgtwo.api.util.auth.BearerToken\nimport com.wgtwo.api.v0.webterminal.WebTerminalMessage\nimport com.wgtwo.api.v0.webterminal.WebTerminalServiceGrpcKt\nimport kotlinx.coroutines.ExperimentalCoroutinesApi\nimport kotlinx.coroutines.flow.catch\nimport kotlinx.coroutines.flow.collect\nimport kotlinx.coroutines.flow.flow\nimport kotlinx.coroutines.flow.onCompletion\nimport kotlinx.coroutines.runBlocking\nimport java.util.*\n\nprivate val channel = Channels.createChannel(Environment.SANDBOX)\nprivate val credentials =\n BearerToken { \"MY_ACCESS_TOKEN\" } // Add your _client credentials_ access token (not user access token)\nprivate val stub = WebTerminalServiceGrpcKt.WebTerminalServiceCoroutineStub(channel)\n .withCallCredentials(credentials)\n\n@ExperimentalCoroutinesApi\nfun main() {\n // your calles's MSISDN goes here\n val to = \"1234567890\"\n\n // your SDP goes here\n val sdp = \"\"\n\n // Pipe() ignores callId, but it's mandatory for MultiPipe()\n val callId = UUID.randomUUID().toString()\n\n // building Offer\n val toPhone = PhoneNumberProto.PhoneNumber.newBuilder().setE164(to).build()\n val offer = WebTerminalMessage.newBuilder().apply {\n offerBuilder.also {\n it.msisdn = toPhone\n it.sdp = sdp\n }\n this.callId = callId\n }.build()\n\n val requests = flow {\n emit(offer)\n }\n\n runBlocking {\n stub.pipe(requests).onCompletion {\n println(\"stream closed\")\n }.catch { t ->\n println(\"got error $t\")\n }.collect {\n println(\"got message $it\")\n }\n }\n}\n"},{"file":"examples/grpcurl/thirdpartydev/webterminal/initiatecall.sh","content":"# Access token must be obtained via the client credentials flow\ngrpcurl \\\n -H \"Authorization: Bearer ${ACCESS_TOKEN}\"\\\n -import-path . \\\n -proto wgtwo/webterminal/v0/webterminal.proto \\\n -d '\n {\n call_id = \"b5289ac4-d254-4d75-8b45-a8c5f5cf47b0\"\n offer = {\n sdp=\"\",\n msisdn = {\n e164 = \"+1234567890\"\n }\n }\n }\n ' \\\n api.wgtwo.com:443 \\\n wgtwo.webterminal.v0.WebTerminalService/Pipe\n"}]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Create a Web Terminal to make and receive calls","headings":[{"value":"Make and receive WebRTC calls"}],"subtitles":[{"depth":1,"value":"Make and receive WebRTC calls","anchor":"#make-and-receive-webrtc-calls"},{"depth":2,"value":"Prerequisites","anchor":"#prerequisites"},{"depth":2,"value":"Overview","anchor":"#overview"},{"depth":2,"value":"The API","anchor":"#the-api"},{"depth":3,"value":"Example code","anchor":"#example-code"},{"depth":3,"value":"Common scenarios","anchor":"#common-scenarios"},{"depth":4,"value":"Initiating a call from a WebRTC terminal","anchor":"#initiating-a-call-from-a-webrtc-terminal"},{"depth":4,"value":"Receiving an incoming call from the core","anchor":"#receiving-an-incoming-call-from-the-core"},{"depth":4,"value":"Observing status","anchor":"#observing-status"},{"depth":4,"value":"Transferring call to Terminal","anchor":"#transferring-call-to-terminal"},{"depth":4,"value":"Transferring call to the mobile terminal","anchor":"#transferring-call-to-the-mobile-terminal"},{"depth":4,"value":"ICE","anchor":"#ice"},{"depth":4,"value":"Renegotiating SDP","anchor":"#renegotiating-sdp"},{"depth":2,"value":"Concepts","anchor":"#concepts"}],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[{"file":"examples/kotlin/thirdpartydev/webterminal/src/main/kotlin/com/wgtwo/examples/thirdpartydev/webterminal/InitiateCall.kt","content":"package com.wgtwo.examples.thirdpartydev.webterminal\n\nimport com.wgtwo.api.common.Environment\nimport com.wgtwo.api.v0.common.PhoneNumberProto\nimport com.wgtwo.api.util.auth.Channels\nimport com.wgtwo.api.util.auth.BearerToken\nimport com.wgtwo.api.v0.webterminal.WebTerminalMessage\nimport com.wgtwo.api.v0.webterminal.WebTerminalServiceGrpcKt\nimport kotlinx.coroutines.ExperimentalCoroutinesApi\nimport kotlinx.coroutines.flow.catch\nimport kotlinx.coroutines.flow.collect\nimport kotlinx.coroutines.flow.flow\nimport kotlinx.coroutines.flow.onCompletion\nimport kotlinx.coroutines.runBlocking\nimport java.util.*\n\nprivate val channel = Channels.createChannel(Environment.SANDBOX)\nprivate val credentials =\n BearerToken { \"MY_ACCESS_TOKEN\" } // Add your _client credentials_ access token (not user access token)\nprivate val stub = WebTerminalServiceGrpcKt.WebTerminalServiceCoroutineStub(channel)\n .withCallCredentials(credentials)\n\n@ExperimentalCoroutinesApi\nfun main() {\n // your calles's MSISDN goes here\n val to = \"1234567890\"\n\n // your SDP goes here\n val sdp = \"\"\n\n // Pipe() ignores callId, but it's mandatory for MultiPipe()\n val callId = UUID.randomUUID().toString()\n\n // building Offer\n val toPhone = PhoneNumberProto.PhoneNumber.newBuilder().setE164(to).build()\n val offer = WebTerminalMessage.newBuilder().apply {\n offerBuilder.also {\n it.msisdn = toPhone\n it.sdp = sdp\n }\n this.callId = callId\n }.build()\n\n val requests = flow {\n emit(offer)\n }\n\n runBlocking {\n stub.pipe(requests).onCompletion {\n println(\"stream closed\")\n }.catch { t ->\n println(\"got error $t\")\n }.collect {\n println(\"got message $it\")\n }\n }\n}\n"},{"file":"examples/grpcurl/thirdpartydev/webterminal/initiatecall.sh","content":"# Access token must be obtained via the client credentials flow\ngrpcurl \\\n -H \"Authorization: Bearer ${ACCESS_TOKEN}\"\\\n -import-path . \\\n -proto wgtwo/webterminal/v0/webterminal.proto \\\n -d '\n {\n call_id = \"b5289ac4-d254-4d75-8b45-a8c5f5cf47b0\"\n offer = {\n sdp=\"\",\n msisdn = {\n e164 = \"+1234567890\"\n }\n }\n }\n ' \\\n api.wgtwo.com:443 \\\n wgtwo.webterminal.v0.WebTerminalService/Pipe\n"}]}},"context":{}} \ No newline at end of file diff --git a/assets/data/web-terminal/web-terminal-api-reference/index.json b/assets/data/web-terminal/web-terminal-api-reference/index.json index 982dee9b..9f14405b 100644 --- a/assets/data/web-terminal/web-terminal-api-reference/index.json +++ b/assets/data/web-terminal/web-terminal-api-reference/index.json @@ -1 +1 @@ -{"hash":"93a05945bb2356491581238933ccec9332b118e3","data":{"doc":{"title":"Web Terminal API reference","headings":[],"subtitles":[],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file +{"hash":"baf0cdb5be8adc9eef821fdae85c0fc47b9f0f4d","data":{"doc":{"title":"Web Terminal API reference","headings":[],"subtitles":[],"roles":["THIRD_PARTY_DEVELOPER","OPERATOR"],"hideWarning":null,"sourceExamples":[]}},"context":{}} \ No newline at end of file diff --git a/assets/js/app.71c4068d.js b/assets/js/app.1d418e6c.js similarity index 99% rename from assets/js/app.71c4068d.js rename to assets/js/app.1d418e6c.js index 69ad5ca7..b95608fc 100644 --- a/assets/js/app.71c4068d.js +++ b/assets/js/app.1d418e6c.js @@ -1,4 +1,4 @@ -(window.webpackJsonp=window.webpackJsonp||[]).push([[0],[]]);!function(t){function e(e){for(var i,o,s=e[0],c=e[1],u=e[2],d=0,f=[];d")})),l="$0"==="a".replace(/./,"$0"),d=a("replace"),f=!!/./[d]&&""===/./[d]("a","$0"),h=!r((function(){var t=/(?:)/,e=t.exec;t.exec=function(){return e.apply(this,arguments)};var n="ab".split(t);return 2!==n.length||"a"!==n[0]||"b"!==n[1]}));t.exports=function(t,e,n,d){var p=a(t),m=!r((function(){var e={};return e[p]=function(){return 7},7!=""[t](e)})),v=m&&!r((function(){var e=!1,n=/a/;return"split"===t&&((n={}).constructor={},n.constructor[c]=function(){return n},n.flags="",n[p]=/./[p]),n.exec=function(){return e=!0,null},n[p](""),!e}));if(!m||!v||"replace"===t&&(!u||!l||f)||"split"===t&&!h){var g=/./[p],y=n(p,""[t],(function(t,e,n,i,r){return e.exec===o?m&&!r?{done:!0,value:g.call(e,n,i)}:{done:!0,value:t.call(n,e,i)}:{done:!1}}),{REPLACE_KEEPS_$0:l,REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE:f}),b=y[0],w=y[1];i(String.prototype,t,b),i(RegExp.prototype,p,2==e?function(t,e){return w.call(t,this,e)}:function(t){return w.call(t,this)})}d&&s(RegExp.prototype[p],"sham",!0)}},"1E5z":function(t,e,n){var i=n("m/L8").f,r=n("UTVS"),a=n("tiKp")("toStringTag");t.exports=function(t,e,n){t&&!r(t=n?t:t.prototype,a)&&i(t,a,{configurable:!0,value:e})}},"1Y/n":function(t,e,n){var i=n("HAuM"),r=n("ewvW"),a=n("RK3t"),o=n("UMSQ"),s=function(t){return function(e,n,s,c){i(n);var u=r(e),l=a(u),d=o(u.length),f=t?d-1:0,h=t?-1:1;if(s<2)for(;;){if(f in l){c=l[f],f+=h;break}if(f+=h,t?f<0:d<=f)throw TypeError("Reduce of empty array with no initial value")}for(;t?f>=0:d>f;f+=h)f in l&&(c=n(c,l[f],f,u));return c}};t.exports={left:s(!1),right:s(!0)}},"2B1R":function(t,e,n){"use strict";var i=n("I+eb"),r=n("tycR").map,a=n("Hd5f"),o=n("rkAj"),s=a("map"),c=o("map");i({target:"Array",proto:!0,forced:!s||!c},{map:function(t){return r(this,t,arguments.length>1?arguments[1]:void 0)}})},"2oRo":function(t,e,n){(function(e){var n=function(t){return t&&t.Math==Math&&t};t.exports=n("object"==typeof globalThis&&globalThis)||n("object"==typeof window&&window)||n("object"==typeof self&&self)||n("object"==typeof e&&e)||Function("return this")()}).call(this,n("ozDA"))},"33Wh":function(t,e,n){var i=n("yoRg"),r=n("eDl+");t.exports=Object.keys||function(t){return i(t,r)}},"3bBZ":function(t,e,n){var i=n("2oRo"),r=n("/byt"),a=n("4mDm"),o=n("kRJp"),s=n("tiKp"),c=s("iterator"),u=s("toStringTag"),l=a.values;for(var d in r){var f=i[d],h=f&&f.prototype;if(h){if(h[c]!==l)try{o(h,c,l)}catch(t){h[c]=l}if(h[u]||o(h,u,d),r[d])for(var p in a)if(h[p]!==a[p])try{o(h,p,a[p])}catch(t){h[p]=a[p]}}}},"3eEr":function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("toAl");function r(t,e){if(t){if("string"==typeof t)return Object(i.a)(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Object(i.a)(t,e):void 0}}},"49sm":function(t,e){var n={}.toString;t.exports=Array.isArray||function(t){return"[object Array]"==n.call(t)}},"4WOD":function(t,e,n){var i=n("UTVS"),r=n("ewvW"),a=n("93I0"),o=n("4Xet"),s=a("IE_PROTO"),c=Object.prototype;t.exports=o?Object.getPrototypeOf:function(t){return t=r(t),i(t,s)?t[s]:"function"==typeof t.constructor&&t instanceof t.constructor?t.constructor.prototype:t instanceof Object?c:null}},"4Xet":function(t,e,n){var i=n("0Dky");t.exports=!i((function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype}))},"4l63":function(t,e,n){var i=n("I+eb"),r=n("wg0c");i({global:!0,forced:parseInt!=r},{parseInt:r})},"4mDm":function(t,e,n){"use strict";var i=n("/GqU"),r=n("RNIs"),a=n("P4y1"),o=n("afO8"),s=n("fdAy"),c=o.set,u=o.getterFor("Array Iterator");t.exports=s(Array,"Array",(function(t,e){c(this,{type:"Array Iterator",target:i(t),index:0,kind:e})}),(function(){var t=u(this),e=t.target,n=t.kind,i=t.index++;return!e||i>=e.length?(t.target=void 0,{value:void 0,done:!0}):"keys"==n?{value:i,done:!1}:"values"==n?{value:e[i],done:!1}:{value:[i,e[i]],done:!1}}),"values"),a.Arguments=a.Array,r("keys"),r("values"),r("entries")},"4syw":function(t,e,n){var i=n("busE");t.exports=function(t,e,n){for(var r in e)i(t,r,e[r],n);return t}},"5GeT":function(t,e,n){"use strict";(function(t){var i=n("xTJ+"),r=n("eRe6"),a=n("RYHr");function o(t){return i.a.isPlainObject(t)||i.a.isArray(t)}function s(t){return i.a.endsWith(t,"[]")?t.slice(0,-2):t}function c(t,e,n){return t?t.concat(e).map((function(t,e){return t=s(t),!n&&e?"["+t+"]":t})).join(n?".":""):e}const u=i.a.toFlatObject(i.a,{},null,(function(t){return/^is[A-Z]/.test(t)}));e.a=function(e,n,l){if(!i.a.isObject(e))throw new TypeError("target must be an object");n=n||new(a.a||FormData);const d=(l=i.a.toFlatObject(l,{metaTokens:!0,dots:!1,indexes:!1},!1,(function(t,e){return!i.a.isUndefined(e[t])}))).metaTokens,f=l.visitor||g,h=l.dots,p=l.indexes,m=(l.Blob||"undefined"!=typeof Blob&&Blob)&&i.a.isSpecCompliantForm(n);if(!i.a.isFunction(f))throw new TypeError("visitor must be a function");function v(e){if(null===e)return"";if(i.a.isDate(e))return e.toISOString();if(!m&&i.a.isBlob(e))throw new r.a("Blob is not supported. Use a Buffer instead.");return i.a.isArrayBuffer(e)||i.a.isTypedArray(e)?m&&"function"==typeof Blob?new Blob([e]):t.from(e):e}function g(t,e,r){let a=t;if(t&&!r&&"object"==typeof t)if(i.a.endsWith(e,"{}"))e=d?e:e.slice(0,-2),t=JSON.stringify(t);else if(i.a.isArray(t)&&function(t){return i.a.isArray(t)&&!t.some(o)}(t)||(i.a.isFileList(t)||i.a.endsWith(e,"[]"))&&(a=i.a.toArray(t)))return e=s(e),a.forEach((function(t,r){!i.a.isUndefined(t)&&null!==t&&n.append(!0===p?c([e],r,h):null===p?e:e+"[]",v(t))})),!1;return!!o(t)||(n.append(c(r,e,h),v(t)),!1)}const y=[],b=Object.assign(u,{defaultVisitor:g,convertValue:v,isVisitable:o});if(!i.a.isObject(e))throw new TypeError("data must be an object");return function t(e,r){if(!i.a.isUndefined(e)){if(-1!==y.indexOf(e))throw Error("Circular reference detected in "+r.join("."));y.push(e),i.a.forEach(e,(function(e,a){!0===(!(i.a.isUndefined(e)||null===e)&&f.call(n,e,i.a.isString(a)?a.trim():a,r,b))&&t(e,r?r.concat(a):[a])})),y.pop()}}(e),n}}).call(this,n("HDXh").Buffer)},"5KoV":function(t,e,n){"use strict";n.d(e,"c",(function(){return s})),n.d(e,"b",(function(){return c})),n.d(e,"a",(function(){return u}));var i=n("Kw5r"),r=n("fVfk"),a=i.a.observable({}),o=function(t){return Object(r.e)(t)||"/"};function s(t,e){return i.a.set(a,o(t),e)}function c(t){return a[o(t)]}function u(t,e){var n=e.matched[0],i=n?n.components.default:{};t.stringified&&i.__file&&console.error("An error occurred while executing "+"query for ".concat(i.__file,"\n\n")+"Error: ".concat(t.stringified))}},"5Yz+":function(t,e,n){"use strict";var i=n("/GqU"),r=n("ppGB"),a=n("UMSQ"),o=n("pkCn"),s=n("rkAj"),c=Math.min,u=[].lastIndexOf,l=!!u&&1/[1].lastIndexOf(1,-0)<0,d=o("lastIndexOf"),f=s("indexOf",{ACCESSORS:!0,1:0}),h=l||!d||!f;t.exports=h?function(t){if(l)return u.apply(this,arguments)||0;var e=i(this),n=a(e.length),o=n-1;for(arguments.length>1&&(o=c(o,r(arguments[1]))),o<0&&(o=n+o);o>=0;o--)if(o in e&&e[o]===t)return o||0;return-1}:u},"5mdu":function(t,e){t.exports=function(t){try{return{error:!1,value:t()}}catch(t){return{error:!0,value:t}}}},"5s+n":function(t,e,n){"use strict";var i,r,a,o,s=n("I+eb"),c=n("xDBR"),u=n("2oRo"),l=n("0GbY"),d=n("/qmn"),f=n("busE"),h=n("4syw"),p=n("1E5z"),m=n("JiZb"),v=n("hh1v"),g=n("HAuM"),y=n("GarU"),b=n("xrYK"),w=n("iSVu"),k=n("ImZN"),S=n("HH4o"),_=n("SEBh"),x=n("LPSS").set,C=n("tXUg"),A=n("zfnd"),D=n("RN6c"),O=n("8GlL"),E=n("5mdu"),T=n("afO8"),$=n("lMq5"),P=n("tiKp"),I=n("LQDL"),R=P("species"),M="Promise",B=T.get,N=T.set,F=T.getterFor(M),L=d,j=u.TypeError,V=u.document,z=u.process,H=l("fetch"),U=O.f,W=U,Y="process"==b(z),K=!!(V&&V.createEvent&&u.dispatchEvent),q=$(M,(function(){if(!(w(L)!==String(L))){if(66===I)return!0;if(!Y&&"function"!=typeof PromiseRejectionEvent)return!0}if(c&&!L.prototype.finally)return!0;if(I>=51&&/native code/.test(L))return!1;var t=L.resolve(1),e=function(t){t((function(){}),(function(){}))};return(t.constructor={})[R]=e,!(t.then((function(){}))instanceof e)})),G=q||!S((function(t){L.all(t).catch((function(){}))})),X=function(t){var e;return!(!v(t)||"function"!=typeof(e=t.then))&&e},J=function(t,e,n){if(!e.notified){e.notified=!0;var i=e.reactions;C((function(){for(var r=e.value,a=1==e.state,o=0;i.length>o;){var s,c,u,l=i[o++],d=a?l.ok:l.fail,f=l.resolve,h=l.reject,p=l.domain;try{d?(a||(2===e.rejection&&et(t,e),e.rejection=1),!0===d?s=r:(p&&p.enter(),s=d(r),p&&(p.exit(),u=!0)),s===l.promise?h(j("Promise-chain cycle")):(c=X(s))?c.call(s,f,h):f(s)):h(r)}catch(t){p&&!u&&p.exit(),h(t)}}e.reactions=[],e.notified=!1,n&&!e.rejection&&Q(t,e)}))}},Z=function(t,e,n){var i,r;K?((i=V.createEvent("Event")).promise=e,i.reason=n,i.initEvent(t,!1,!0),u.dispatchEvent(i)):i={promise:e,reason:n},(r=u["on"+t])?r(i):"unhandledrejection"===t&&D("Unhandled promise rejection",n)},Q=function(t,e){x.call(u,(function(){var n,i=e.value;if(tt(e)&&(n=E((function(){Y?z.emit("unhandledRejection",i,t):Z("unhandledrejection",t,i)})),e.rejection=Y||tt(e)?2:1,n.error))throw n.value}))},tt=function(t){return 1!==t.rejection&&!t.parent},et=function(t,e){x.call(u,(function(){Y?z.emit("rejectionHandled",t):Z("rejectionhandled",t,e.value)}))},nt=function(t,e,n,i){return function(r){t(e,n,r,i)}},it=function(t,e,n,i){e.done||(e.done=!0,i&&(e=i),e.value=n,e.state=2,J(t,e,!0))},rt=function(t,e,n,i){if(!e.done){e.done=!0,i&&(e=i);try{if(t===n)throw j("Promise can't be resolved itself");var r=X(n);r?C((function(){var i={done:!1};try{r.call(n,nt(rt,t,i,e),nt(it,t,i,e))}catch(n){it(t,i,n,e)}})):(e.value=n,e.state=1,J(t,e,!1))}catch(n){it(t,{done:!1},n,e)}}};q&&(L=function(t){y(this,L,M),g(t),i.call(this);var e=B(this);try{t(nt(rt,this,e),nt(it,this,e))}catch(t){it(this,e,t)}},(i=function(t){N(this,{type:M,done:!1,notified:!1,parent:!1,reactions:[],rejection:!1,state:0,value:void 0})}).prototype=h(L.prototype,{then:function(t,e){var n=F(this),i=U(_(this,L));return i.ok="function"!=typeof t||t,i.fail="function"==typeof e&&e,i.domain=Y?z.domain:void 0,n.parent=!0,n.reactions.push(i),0!=n.state&&J(this,n,!1),i.promise},catch:function(t){return this.then(void 0,t)}}),r=function(){var t=new i,e=B(t);this.promise=t,this.resolve=nt(rt,t,e),this.reject=nt(it,t,e)},O.f=U=function(t){return t===L||t===a?new r(t):W(t)},c||"function"!=typeof d||(o=d.prototype.then,f(d.prototype,"then",(function(t,e){var n=this;return new L((function(t,e){o.call(n,t,e)})).then(t,e)}),{unsafe:!0}),"function"==typeof H&&s({global:!0,enumerable:!0,forced:!0},{fetch:function(t){return A(L,H.apply(u,arguments))}}))),s({global:!0,wrap:!0,forced:q},{Promise:L}),p(L,M,!1,!0),m(M),a=l(M),s({target:M,stat:!0,forced:q},{reject:function(t){var e=U(this);return e.reject.call(void 0,t),e.promise}}),s({target:M,stat:!0,forced:c||q},{resolve:function(t){return A(c&&this===a?L:this,t)}}),s({target:M,stat:!0,forced:G},{all:function(t){var e=this,n=U(e),i=n.resolve,r=n.reject,a=E((function(){var n=g(e.resolve),a=[],o=0,s=1;k(t,(function(t){var c=o++,u=!1;a.push(void 0),s++,n.call(e,t).then((function(t){u||(u=!0,a[c]=t,--s||i(a))}),r)})),--s||i(a)}));return a.error&&r(a.value),n.promise},race:function(t){var e=this,n=U(e),i=n.reject,r=E((function(){var r=g(e.resolve);k(t,(function(t){r.call(e,t).then(n.resolve,i)}))}));return r.error&&i(r.value),n.promise}})},"6JNq":function(t,e,n){var i=n("UTVS"),r=n("Vu81"),a=n("Bs8V"),o=n("m/L8");t.exports=function(t,e){for(var n=r(e),s=o.f,c=a.f,u=0;u1?arguments[1]:void 0)}})},EnZy:function(t,e,n){"use strict";var i=n("14Sl"),r=n("ROdP"),a=n("glrk"),o=n("HYAF"),s=n("SEBh"),c=n("iqWW"),u=n("UMSQ"),l=n("FMNM"),d=n("kmMV"),f=n("0Dky"),h=[].push,p=Math.min,m=!f((function(){return!RegExp(4294967295,"y")}));i("split",2,(function(t,e,n){var i;return i="c"=="abbc".split(/(b)*/)[1]||4!="test".split(/(?:)/,-1).length||2!="ab".split(/(?:ab)*/).length||4!=".".split(/(.?)(.?)/).length||".".split(/()()/).length>1||"".split(/.?/).length?function(t,n){var i=String(o(this)),a=void 0===n?4294967295:n>>>0;if(0===a)return[];if(void 0===t)return[i];if(!r(t))return e.call(i,t,a);for(var s,c,u,l=[],f=(t.ignoreCase?"i":"")+(t.multiline?"m":"")+(t.unicode?"u":"")+(t.sticky?"y":""),p=0,m=new RegExp(t.source,f+"g");(s=d.call(m,i))&&!((c=m.lastIndex)>p&&(l.push(i.slice(p,s.index)),s.length>1&&s.index=a));)m.lastIndex===s.index&&m.lastIndex++;return p===i.length?!u&&m.test("")||l.push(""):l.push(i.slice(p)),l.length>a?l.slice(0,a):l}:"0".split(void 0,0).length?function(t,n){return void 0===t&&0===n?[]:e.call(this,t,n)}:e,[function(e,n){var r=o(this),a=null==e?void 0:e[t];return void 0!==a?a.call(e,r,n):i.call(String(r),e,n)},function(t,r){var o=n(i,t,this,r,i!==e);if(o.done)return o.value;var d=a(t),f=String(this),h=s(d,RegExp),v=d.unicode,g=(d.ignoreCase?"i":"")+(d.multiline?"m":"")+(d.unicode?"u":"")+(m?"y":"g"),y=new h(m?d:"^(?:"+d.source+")",g),b=void 0===r?4294967295:r>>>0;if(0===b)return[];if(0===f.length)return null===l(y,f)?[f]:[];for(var w=0,k=0,S=[];k1?arguments[1]:void 0)}},FMNM:function(t,e,n){var i=n("xrYK"),r=n("kmMV");t.exports=function(t,e){var n=t.exec;if("function"==typeof n){var a=n.call(t,e);if("object"!=typeof a)throw TypeError("RegExp exec method returned something other than an Object or null");return a}if("RegExp"!==i(t))throw TypeError("RegExp#exec called on incompatible receiver");return r.call(t,e)}},FZtP:function(t,e,n){var i=n("2oRo"),r=n("/byt"),a=n("F8JR"),o=n("kRJp");for(var s in r){var c=i[s],u=c&&c.prototype;if(u&&u.forEach!==a)try{o(u,"forEach",a)}catch(t){u.forEach=a}}},"G+Rx":function(t,e,n){var i=n("0GbY");t.exports=i("document","documentElement")},GYl3:function(t,e){Prism.languages.go=Prism.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"|`[^`]*`/,lookbehind:!0,greedy:!0},keyword:/\b(?:break|case|chan|const|continue|default|defer|else|fallthrough|for|func|go(?:to)?|if|import|interface|map|package|range|return|select|struct|switch|type|var)\b/,boolean:/\b(?:_|false|iota|nil|true)\b/,number:[/\b0(?:b[01_]+|o[0-7_]+)i?\b/i,/\b0x(?:[a-f\d_]+(?:\.[a-f\d_]*)?|\.[a-f\d_]+)(?:p[+-]?\d+(?:_\d+)*)?i?(?!\w)/i,/(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?[\d_]+)?i?(?!\w)/i],operator:/[*\/%^!=]=?|\+[=+]?|-[=-]?|\|[=|]?|&(?:=|&|\^=?)?|>(?:>=?|=)?|<(?:<=?|=|-)?|:=|\.\.\./,builtin:/\b(?:append|bool|byte|cap|close|complex|complex(?:64|128)|copy|delete|error|float(?:32|64)|u?int(?:8|16|32|64)?|imag|len|make|new|panic|print(?:ln)?|real|recover|rune|string|uintptr)\b/}),Prism.languages.insertBefore("go","string",{char:{pattern:/'(?:\\.|[^'\\\r\n]){0,10}'/,greedy:!0}}),delete Prism.languages.go["class-name"]},GarU:function(t,e){t.exports=function(t,e,n){if(!(t instanceof e))throw TypeError("Incorrect "+(n?n+" ":"")+"invocation");return t}},H7XF:function(t,e,n){"use strict";e.byteLength=function(t){var e=u(t),n=e[0],i=e[1];return 3*(n+i)/4-i},e.toByteArray=function(t){var e,n,i=u(t),o=i[0],s=i[1],c=new a(function(t,e,n){return 3*(e+n)/4-n}(0,o,s)),l=0,d=s>0?o-4:o;for(n=0;n>16&255,c[l++]=e>>8&255,c[l++]=255&e;2===s&&(e=r[t.charCodeAt(n)]<<2|r[t.charCodeAt(n+1)]>>4,c[l++]=255&e);1===s&&(e=r[t.charCodeAt(n)]<<10|r[t.charCodeAt(n+1)]<<4|r[t.charCodeAt(n+2)]>>2,c[l++]=e>>8&255,c[l++]=255&e);return c},e.fromByteArray=function(t){for(var e,n=t.length,r=n%3,a=[],o=0,s=n-r;os?s:o+16383));1===r?(e=t[n-1],a.push(i[e>>2]+i[e<<4&63]+"==")):2===r&&(e=(t[n-2]<<8)+t[n-1],a.push(i[e>>10]+i[e>>4&63]+i[e<<2&63]+"="));return a.join("")};for(var i=[],r=[],a="undefined"!=typeof Uint8Array?Uint8Array:Array,o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,c=o.length;s0)throw new Error("Invalid string. Length must be a multiple of 4");var n=t.indexOf("=");return-1===n&&(n=e),[n,n===e?0:4-n%4]}function l(t,e,n){for(var r,a,o=[],s=e;s>18&63]+i[a>>12&63]+i[a>>6&63]+i[63&a]);return o.join("")}r["-".charCodeAt(0)]=62,r["_".charCodeAt(0)]=63},HAuM:function(t,e){t.exports=function(t){if("function"!=typeof t)throw TypeError(String(t)+" is not a function");return t}},HDXh:function(t,e,n){"use strict";(function(t){ +(window.webpackJsonp=window.webpackJsonp||[]).push([[0],[]]);!function(t){function e(e){for(var i,o,s=e[0],c=e[1],u=e[2],d=0,f=[];d")})),l="$0"==="a".replace(/./,"$0"),d=a("replace"),f=!!/./[d]&&""===/./[d]("a","$0"),h=!r((function(){var t=/(?:)/,e=t.exec;t.exec=function(){return e.apply(this,arguments)};var n="ab".split(t);return 2!==n.length||"a"!==n[0]||"b"!==n[1]}));t.exports=function(t,e,n,d){var p=a(t),m=!r((function(){var e={};return e[p]=function(){return 7},7!=""[t](e)})),v=m&&!r((function(){var e=!1,n=/a/;return"split"===t&&((n={}).constructor={},n.constructor[c]=function(){return n},n.flags="",n[p]=/./[p]),n.exec=function(){return e=!0,null},n[p](""),!e}));if(!m||!v||"replace"===t&&(!u||!l||f)||"split"===t&&!h){var g=/./[p],y=n(p,""[t],(function(t,e,n,i,r){return e.exec===o?m&&!r?{done:!0,value:g.call(e,n,i)}:{done:!0,value:t.call(n,e,i)}:{done:!1}}),{REPLACE_KEEPS_$0:l,REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE:f}),b=y[0],w=y[1];i(String.prototype,t,b),i(RegExp.prototype,p,2==e?function(t,e){return w.call(t,this,e)}:function(t){return w.call(t,this)})}d&&s(RegExp.prototype[p],"sham",!0)}},"1E5z":function(t,e,n){var i=n("m/L8").f,r=n("UTVS"),a=n("tiKp")("toStringTag");t.exports=function(t,e,n){t&&!r(t=n?t:t.prototype,a)&&i(t,a,{configurable:!0,value:e})}},"1Y/n":function(t,e,n){var i=n("HAuM"),r=n("ewvW"),a=n("RK3t"),o=n("UMSQ"),s=function(t){return function(e,n,s,c){i(n);var u=r(e),l=a(u),d=o(u.length),f=t?d-1:0,h=t?-1:1;if(s<2)for(;;){if(f in l){c=l[f],f+=h;break}if(f+=h,t?f<0:d<=f)throw TypeError("Reduce of empty array with no initial value")}for(;t?f>=0:d>f;f+=h)f in l&&(c=n(c,l[f],f,u));return c}};t.exports={left:s(!1),right:s(!0)}},"2B1R":function(t,e,n){"use strict";var i=n("I+eb"),r=n("tycR").map,a=n("Hd5f"),o=n("rkAj"),s=a("map"),c=o("map");i({target:"Array",proto:!0,forced:!s||!c},{map:function(t){return r(this,t,arguments.length>1?arguments[1]:void 0)}})},"2oRo":function(t,e,n){(function(e){var n=function(t){return t&&t.Math==Math&&t};t.exports=n("object"==typeof globalThis&&globalThis)||n("object"==typeof window&&window)||n("object"==typeof self&&self)||n("object"==typeof e&&e)||Function("return this")()}).call(this,n("ozDA"))},"33Wh":function(t,e,n){var i=n("yoRg"),r=n("eDl+");t.exports=Object.keys||function(t){return i(t,r)}},"3bBZ":function(t,e,n){var i=n("2oRo"),r=n("/byt"),a=n("4mDm"),o=n("kRJp"),s=n("tiKp"),c=s("iterator"),u=s("toStringTag"),l=a.values;for(var d in r){var f=i[d],h=f&&f.prototype;if(h){if(h[c]!==l)try{o(h,c,l)}catch(t){h[c]=l}if(h[u]||o(h,u,d),r[d])for(var p in a)if(h[p]!==a[p])try{o(h,p,a[p])}catch(t){h[p]=a[p]}}}},"3eEr":function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var i=n("toAl");function r(t,e){if(t){if("string"==typeof t)return Object(i.a)(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Object(i.a)(t,e):void 0}}},"49sm":function(t,e){var n={}.toString;t.exports=Array.isArray||function(t){return"[object Array]"==n.call(t)}},"4WOD":function(t,e,n){var i=n("UTVS"),r=n("ewvW"),a=n("93I0"),o=n("4Xet"),s=a("IE_PROTO"),c=Object.prototype;t.exports=o?Object.getPrototypeOf:function(t){return t=r(t),i(t,s)?t[s]:"function"==typeof t.constructor&&t instanceof t.constructor?t.constructor.prototype:t instanceof Object?c:null}},"4Xet":function(t,e,n){var i=n("0Dky");t.exports=!i((function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype}))},"4l63":function(t,e,n){var i=n("I+eb"),r=n("wg0c");i({global:!0,forced:parseInt!=r},{parseInt:r})},"4mDm":function(t,e,n){"use strict";var i=n("/GqU"),r=n("RNIs"),a=n("P4y1"),o=n("afO8"),s=n("fdAy"),c=o.set,u=o.getterFor("Array Iterator");t.exports=s(Array,"Array",(function(t,e){c(this,{type:"Array Iterator",target:i(t),index:0,kind:e})}),(function(){var t=u(this),e=t.target,n=t.kind,i=t.index++;return!e||i>=e.length?(t.target=void 0,{value:void 0,done:!0}):"keys"==n?{value:i,done:!1}:"values"==n?{value:e[i],done:!1}:{value:[i,e[i]],done:!1}}),"values"),a.Arguments=a.Array,r("keys"),r("values"),r("entries")},"4syw":function(t,e,n){var i=n("busE");t.exports=function(t,e,n){for(var r in e)i(t,r,e[r],n);return t}},"5GeT":function(t,e,n){"use strict";(function(t){var i=n("xTJ+"),r=n("eRe6"),a=n("RYHr");function o(t){return i.a.isPlainObject(t)||i.a.isArray(t)}function s(t){return i.a.endsWith(t,"[]")?t.slice(0,-2):t}function c(t,e,n){return t?t.concat(e).map((function(t,e){return t=s(t),!n&&e?"["+t+"]":t})).join(n?".":""):e}const u=i.a.toFlatObject(i.a,{},null,(function(t){return/^is[A-Z]/.test(t)}));e.a=function(e,n,l){if(!i.a.isObject(e))throw new TypeError("target must be an object");n=n||new(a.a||FormData);const d=(l=i.a.toFlatObject(l,{metaTokens:!0,dots:!1,indexes:!1},!1,(function(t,e){return!i.a.isUndefined(e[t])}))).metaTokens,f=l.visitor||g,h=l.dots,p=l.indexes,m=(l.Blob||"undefined"!=typeof Blob&&Blob)&&i.a.isSpecCompliantForm(n);if(!i.a.isFunction(f))throw new TypeError("visitor must be a function");function v(e){if(null===e)return"";if(i.a.isDate(e))return e.toISOString();if(!m&&i.a.isBlob(e))throw new r.a("Blob is not supported. Use a Buffer instead.");return i.a.isArrayBuffer(e)||i.a.isTypedArray(e)?m&&"function"==typeof Blob?new Blob([e]):t.from(e):e}function g(t,e,r){let a=t;if(t&&!r&&"object"==typeof t)if(i.a.endsWith(e,"{}"))e=d?e:e.slice(0,-2),t=JSON.stringify(t);else if(i.a.isArray(t)&&function(t){return i.a.isArray(t)&&!t.some(o)}(t)||(i.a.isFileList(t)||i.a.endsWith(e,"[]"))&&(a=i.a.toArray(t)))return e=s(e),a.forEach((function(t,r){!i.a.isUndefined(t)&&null!==t&&n.append(!0===p?c([e],r,h):null===p?e:e+"[]",v(t))})),!1;return!!o(t)||(n.append(c(r,e,h),v(t)),!1)}const y=[],b=Object.assign(u,{defaultVisitor:g,convertValue:v,isVisitable:o});if(!i.a.isObject(e))throw new TypeError("data must be an object");return function t(e,r){if(!i.a.isUndefined(e)){if(-1!==y.indexOf(e))throw Error("Circular reference detected in "+r.join("."));y.push(e),i.a.forEach(e,(function(e,a){!0===(!(i.a.isUndefined(e)||null===e)&&f.call(n,e,i.a.isString(a)?a.trim():a,r,b))&&t(e,r?r.concat(a):[a])})),y.pop()}}(e),n}}).call(this,n("HDXh").Buffer)},"5KoV":function(t,e,n){"use strict";n.d(e,"c",(function(){return s})),n.d(e,"b",(function(){return c})),n.d(e,"a",(function(){return u}));var i=n("Kw5r"),r=n("fVfk"),a=i.a.observable({}),o=function(t){return Object(r.e)(t)||"/"};function s(t,e){return i.a.set(a,o(t),e)}function c(t){return a[o(t)]}function u(t,e){var n=e.matched[0],i=n?n.components.default:{};t.stringified&&i.__file&&console.error("An error occurred while executing "+"query for ".concat(i.__file,"\n\n")+"Error: ".concat(t.stringified))}},"5Yz+":function(t,e,n){"use strict";var i=n("/GqU"),r=n("ppGB"),a=n("UMSQ"),o=n("pkCn"),s=n("rkAj"),c=Math.min,u=[].lastIndexOf,l=!!u&&1/[1].lastIndexOf(1,-0)<0,d=o("lastIndexOf"),f=s("indexOf",{ACCESSORS:!0,1:0}),h=l||!d||!f;t.exports=h?function(t){if(l)return u.apply(this,arguments)||0;var e=i(this),n=a(e.length),o=n-1;for(arguments.length>1&&(o=c(o,r(arguments[1]))),o<0&&(o=n+o);o>=0;o--)if(o in e&&e[o]===t)return o||0;return-1}:u},"5mdu":function(t,e){t.exports=function(t){try{return{error:!1,value:t()}}catch(t){return{error:!0,value:t}}}},"5s+n":function(t,e,n){"use strict";var i,r,a,o,s=n("I+eb"),c=n("xDBR"),u=n("2oRo"),l=n("0GbY"),d=n("/qmn"),f=n("busE"),h=n("4syw"),p=n("1E5z"),m=n("JiZb"),v=n("hh1v"),g=n("HAuM"),y=n("GarU"),b=n("xrYK"),w=n("iSVu"),k=n("ImZN"),S=n("HH4o"),_=n("SEBh"),x=n("LPSS").set,C=n("tXUg"),A=n("zfnd"),D=n("RN6c"),O=n("8GlL"),E=n("5mdu"),T=n("afO8"),$=n("lMq5"),P=n("tiKp"),I=n("LQDL"),R=P("species"),M="Promise",B=T.get,N=T.set,F=T.getterFor(M),L=d,j=u.TypeError,V=u.document,z=u.process,H=l("fetch"),U=O.f,W=U,Y="process"==b(z),K=!!(V&&V.createEvent&&u.dispatchEvent),q=$(M,(function(){if(!(w(L)!==String(L))){if(66===I)return!0;if(!Y&&"function"!=typeof PromiseRejectionEvent)return!0}if(c&&!L.prototype.finally)return!0;if(I>=51&&/native code/.test(L))return!1;var t=L.resolve(1),e=function(t){t((function(){}),(function(){}))};return(t.constructor={})[R]=e,!(t.then((function(){}))instanceof e)})),G=q||!S((function(t){L.all(t).catch((function(){}))})),X=function(t){var e;return!(!v(t)||"function"!=typeof(e=t.then))&&e},J=function(t,e,n){if(!e.notified){e.notified=!0;var i=e.reactions;C((function(){for(var r=e.value,a=1==e.state,o=0;i.length>o;){var s,c,u,l=i[o++],d=a?l.ok:l.fail,f=l.resolve,h=l.reject,p=l.domain;try{d?(a||(2===e.rejection&&et(t,e),e.rejection=1),!0===d?s=r:(p&&p.enter(),s=d(r),p&&(p.exit(),u=!0)),s===l.promise?h(j("Promise-chain cycle")):(c=X(s))?c.call(s,f,h):f(s)):h(r)}catch(t){p&&!u&&p.exit(),h(t)}}e.reactions=[],e.notified=!1,n&&!e.rejection&&Q(t,e)}))}},Z=function(t,e,n){var i,r;K?((i=V.createEvent("Event")).promise=e,i.reason=n,i.initEvent(t,!1,!0),u.dispatchEvent(i)):i={promise:e,reason:n},(r=u["on"+t])?r(i):"unhandledrejection"===t&&D("Unhandled promise rejection",n)},Q=function(t,e){x.call(u,(function(){var n,i=e.value;if(tt(e)&&(n=E((function(){Y?z.emit("unhandledRejection",i,t):Z("unhandledrejection",t,i)})),e.rejection=Y||tt(e)?2:1,n.error))throw n.value}))},tt=function(t){return 1!==t.rejection&&!t.parent},et=function(t,e){x.call(u,(function(){Y?z.emit("rejectionHandled",t):Z("rejectionhandled",t,e.value)}))},nt=function(t,e,n,i){return function(r){t(e,n,r,i)}},it=function(t,e,n,i){e.done||(e.done=!0,i&&(e=i),e.value=n,e.state=2,J(t,e,!0))},rt=function(t,e,n,i){if(!e.done){e.done=!0,i&&(e=i);try{if(t===n)throw j("Promise can't be resolved itself");var r=X(n);r?C((function(){var i={done:!1};try{r.call(n,nt(rt,t,i,e),nt(it,t,i,e))}catch(n){it(t,i,n,e)}})):(e.value=n,e.state=1,J(t,e,!1))}catch(n){it(t,{done:!1},n,e)}}};q&&(L=function(t){y(this,L,M),g(t),i.call(this);var e=B(this);try{t(nt(rt,this,e),nt(it,this,e))}catch(t){it(this,e,t)}},(i=function(t){N(this,{type:M,done:!1,notified:!1,parent:!1,reactions:[],rejection:!1,state:0,value:void 0})}).prototype=h(L.prototype,{then:function(t,e){var n=F(this),i=U(_(this,L));return i.ok="function"!=typeof t||t,i.fail="function"==typeof e&&e,i.domain=Y?z.domain:void 0,n.parent=!0,n.reactions.push(i),0!=n.state&&J(this,n,!1),i.promise},catch:function(t){return this.then(void 0,t)}}),r=function(){var t=new i,e=B(t);this.promise=t,this.resolve=nt(rt,t,e),this.reject=nt(it,t,e)},O.f=U=function(t){return t===L||t===a?new r(t):W(t)},c||"function"!=typeof d||(o=d.prototype.then,f(d.prototype,"then",(function(t,e){var n=this;return new L((function(t,e){o.call(n,t,e)})).then(t,e)}),{unsafe:!0}),"function"==typeof H&&s({global:!0,enumerable:!0,forced:!0},{fetch:function(t){return A(L,H.apply(u,arguments))}}))),s({global:!0,wrap:!0,forced:q},{Promise:L}),p(L,M,!1,!0),m(M),a=l(M),s({target:M,stat:!0,forced:q},{reject:function(t){var e=U(this);return e.reject.call(void 0,t),e.promise}}),s({target:M,stat:!0,forced:c||q},{resolve:function(t){return A(c&&this===a?L:this,t)}}),s({target:M,stat:!0,forced:G},{all:function(t){var e=this,n=U(e),i=n.resolve,r=n.reject,a=E((function(){var n=g(e.resolve),a=[],o=0,s=1;k(t,(function(t){var c=o++,u=!1;a.push(void 0),s++,n.call(e,t).then((function(t){u||(u=!0,a[c]=t,--s||i(a))}),r)})),--s||i(a)}));return a.error&&r(a.value),n.promise},race:function(t){var e=this,n=U(e),i=n.reject,r=E((function(){var r=g(e.resolve);k(t,(function(t){r.call(e,t).then(n.resolve,i)}))}));return r.error&&i(r.value),n.promise}})},"6JNq":function(t,e,n){var i=n("UTVS"),r=n("Vu81"),a=n("Bs8V"),o=n("m/L8");t.exports=function(t,e){for(var n=r(e),s=o.f,c=a.f,u=0;u1?arguments[1]:void 0)}})},EnZy:function(t,e,n){"use strict";var i=n("14Sl"),r=n("ROdP"),a=n("glrk"),o=n("HYAF"),s=n("SEBh"),c=n("iqWW"),u=n("UMSQ"),l=n("FMNM"),d=n("kmMV"),f=n("0Dky"),h=[].push,p=Math.min,m=!f((function(){return!RegExp(4294967295,"y")}));i("split",2,(function(t,e,n){var i;return i="c"=="abbc".split(/(b)*/)[1]||4!="test".split(/(?:)/,-1).length||2!="ab".split(/(?:ab)*/).length||4!=".".split(/(.?)(.?)/).length||".".split(/()()/).length>1||"".split(/.?/).length?function(t,n){var i=String(o(this)),a=void 0===n?4294967295:n>>>0;if(0===a)return[];if(void 0===t)return[i];if(!r(t))return e.call(i,t,a);for(var s,c,u,l=[],f=(t.ignoreCase?"i":"")+(t.multiline?"m":"")+(t.unicode?"u":"")+(t.sticky?"y":""),p=0,m=new RegExp(t.source,f+"g");(s=d.call(m,i))&&!((c=m.lastIndex)>p&&(l.push(i.slice(p,s.index)),s.length>1&&s.index=a));)m.lastIndex===s.index&&m.lastIndex++;return p===i.length?!u&&m.test("")||l.push(""):l.push(i.slice(p)),l.length>a?l.slice(0,a):l}:"0".split(void 0,0).length?function(t,n){return void 0===t&&0===n?[]:e.call(this,t,n)}:e,[function(e,n){var r=o(this),a=null==e?void 0:e[t];return void 0!==a?a.call(e,r,n):i.call(String(r),e,n)},function(t,r){var o=n(i,t,this,r,i!==e);if(o.done)return o.value;var d=a(t),f=String(this),h=s(d,RegExp),v=d.unicode,g=(d.ignoreCase?"i":"")+(d.multiline?"m":"")+(d.unicode?"u":"")+(m?"y":"g"),y=new h(m?d:"^(?:"+d.source+")",g),b=void 0===r?4294967295:r>>>0;if(0===b)return[];if(0===f.length)return null===l(y,f)?[f]:[];for(var w=0,k=0,S=[];k1?arguments[1]:void 0)}},FMNM:function(t,e,n){var i=n("xrYK"),r=n("kmMV");t.exports=function(t,e){var n=t.exec;if("function"==typeof n){var a=n.call(t,e);if("object"!=typeof a)throw TypeError("RegExp exec method returned something other than an Object or null");return a}if("RegExp"!==i(t))throw TypeError("RegExp#exec called on incompatible receiver");return r.call(t,e)}},FZtP:function(t,e,n){var i=n("2oRo"),r=n("/byt"),a=n("F8JR"),o=n("kRJp");for(var s in r){var c=i[s],u=c&&c.prototype;if(u&&u.forEach!==a)try{o(u,"forEach",a)}catch(t){u.forEach=a}}},"G+Rx":function(t,e,n){var i=n("0GbY");t.exports=i("document","documentElement")},GYl3:function(t,e){Prism.languages.go=Prism.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"|`[^`]*`/,lookbehind:!0,greedy:!0},keyword:/\b(?:break|case|chan|const|continue|default|defer|else|fallthrough|for|func|go(?:to)?|if|import|interface|map|package|range|return|select|struct|switch|type|var)\b/,boolean:/\b(?:_|false|iota|nil|true)\b/,number:[/\b0(?:b[01_]+|o[0-7_]+)i?\b/i,/\b0x(?:[a-f\d_]+(?:\.[a-f\d_]*)?|\.[a-f\d_]+)(?:p[+-]?\d+(?:_\d+)*)?i?(?!\w)/i,/(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?[\d_]+)?i?(?!\w)/i],operator:/[*\/%^!=]=?|\+[=+]?|-[=-]?|\|[=|]?|&(?:=|&|\^=?)?|>(?:>=?|=)?|<(?:<=?|=|-)?|:=|\.\.\./,builtin:/\b(?:append|bool|byte|cap|close|complex|complex(?:64|128)|copy|delete|error|float(?:32|64)|u?int(?:8|16|32|64)?|imag|len|make|new|panic|print(?:ln)?|real|recover|rune|string|uintptr)\b/}),Prism.languages.insertBefore("go","string",{char:{pattern:/'(?:\\.|[^'\\\r\n]){0,10}'/,greedy:!0}}),delete Prism.languages.go["class-name"]},GarU:function(t,e){t.exports=function(t,e,n){if(!(t instanceof e))throw TypeError("Incorrect "+(n?n+" ":"")+"invocation");return t}},H7XF:function(t,e,n){"use strict";e.byteLength=function(t){var e=u(t),n=e[0],i=e[1];return 3*(n+i)/4-i},e.toByteArray=function(t){var e,n,i=u(t),o=i[0],s=i[1],c=new a(function(t,e,n){return 3*(e+n)/4-n}(0,o,s)),l=0,d=s>0?o-4:o;for(n=0;n>16&255,c[l++]=e>>8&255,c[l++]=255&e;2===s&&(e=r[t.charCodeAt(n)]<<2|r[t.charCodeAt(n+1)]>>4,c[l++]=255&e);1===s&&(e=r[t.charCodeAt(n)]<<10|r[t.charCodeAt(n+1)]<<4|r[t.charCodeAt(n+2)]>>2,c[l++]=e>>8&255,c[l++]=255&e);return c},e.fromByteArray=function(t){for(var e,n=t.length,r=n%3,a=[],o=0,s=n-r;os?s:o+16383));1===r?(e=t[n-1],a.push(i[e>>2]+i[e<<4&63]+"==")):2===r&&(e=(t[n-2]<<8)+t[n-1],a.push(i[e>>10]+i[e>>4&63]+i[e<<2&63]+"="));return a.join("")};for(var i=[],r=[],a="undefined"!=typeof Uint8Array?Uint8Array:Array,o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,c=o.length;s0)throw new Error("Invalid string. Length must be a multiple of 4");var n=t.indexOf("=");return-1===n&&(n=e),[n,n===e?0:4-n%4]}function l(t,e,n){for(var r,a,o=[],s=e;s>18&63]+i[a>>12&63]+i[a>>6&63]+i[63&a]);return o.join("")}r["-".charCodeAt(0)]=62,r["_".charCodeAt(0)]=63},HAuM:function(t,e){t.exports=function(t){if("function"!=typeof t)throw TypeError(String(t)+" is not a function");return t}},HDXh:function(t,e,n){"use strict";(function(t){ /*! * The buffer module from node.js, for the browser. * diff --git a/assets/js/page--src--templates--doc-page-vue.44e11ace.js b/assets/js/page--src--templates--doc-page-vue.ad9d5276.js similarity index 75% rename from assets/js/page--src--templates--doc-page-vue.44e11ace.js rename to assets/js/page--src--templates--doc-page-vue.ad9d5276.js index 01236cb2..c688b0c4 100644 --- a/assets/js/page--src--templates--doc-page-vue.44e11ace.js +++ b/assets/js/page--src--templates--doc-page-vue.ad9d5276.js @@ -1 +1 @@ -(window.webpackJsonp=window.webpackJsonp||[]).push([[4],{Bo5W:function(e,t,n){"use strict";n("z32d")},DQNa:function(e,t,n){var o=n("busE"),i=Date.prototype,r=i.toString,a=i.getTime;new Date(NaN)+""!="Invalid Date"&&o(i,"toString",(function(){var e=a.call(this);return e==e?r.call(this):"Invalid Date"}))},I1kV:function(e,t,n){},TeQF:function(e,t,n){"use strict";var o=n("I+eb"),i=n("tycR").filter,r=n("Hd5f"),a=n("rkAj"),c=r("filter"),l=a("filter");o({target:"Array",proto:!0,forced:!c||!l},{filter:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},ToJy:function(e,t,n){"use strict";var o=n("I+eb"),i=n("HAuM"),r=n("ewvW"),a=n("0Dky"),c=n("pkCn"),l=[],s=l.sort,p=a((function(){l.sort(void 0)})),d=a((function(){l.sort(null)})),u=c("sort");o({target:"Array",proto:!0,forced:p||!d||!u},{sort:function(e){return void 0===e?s.call(r(this)):s.call(r(this),i(e))}})},Tskq:function(e,t,n){"use strict";var o=n("bWFh"),i=n("ZWaQ");e.exports=o("Map",(function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}}),i)},dDYI:function(e,t,n){"use strict";n.r(t);n("TeQF"),n("yq1k"),n("yXV3"),n("2B1R"),n("ToJy"),n("DQNa"),n("Tskq"),n("07d7"),n("JfAA"),n("YGK4"),n("PKPk"),n("3bBZ");var o=n("VPjN"),i=n("0P+p"),r=n("8/MJ"),a=n("L2JU"),c=n("x2p9"),l=n.n(c),s={methods:{choose:function(e){this.$parent.$emit("input",e),this.$parent.close()}}},p=(n("Bo5W"),n("7uw+")),d={components:{RoleSelection:Object(p.a)(s,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"role-selection card"},[n("div",{staticClass:"card-content content"},[n("h1",[e._v("Who is the user of your product?")]),e._m(0),n("div",{staticClass:"choices"},[n("button",{staticClass:"button is-role",on:{click:function(t){return e.choose("THIRD_PARTY_DEVELOPER")}}},[e._v("Subscribers")]),n("span",[e._v("I'm making a product for subscribers")]),n("button",{staticClass:"button is-role",on:{click:function(t){return e.choose("OPERATOR")}}},[e._v("Telecom operators")]),n("span",[e._v("I'm making a product for telecom operators")]),n("button",{staticClass:"button is-role",on:{click:function(t){return e.choose("")}}},[e._v("No customisation")]),n("span",[e._v("Don't make any customisations to the content")])])])])}),[function(){var e=this.$createElement,t=this._self._c||e;return t("p",[this._v("\n We can customise the content to help you better achieve your goals.\n "),t("br"),this._v("You can change this later.\n ")])}],!1,null,null,null).exports},watch:{"$page.doc.roles":function(e){this.updateAvailableRoles(e)}},methods:Object(r.a)({},Object(a.b)(["updateRole","updateAvailableRoles"])),mounted:function(){this.hasRoleChoiceBeenGiven||this.isRoleModalActive||""!==this.role||(this.isRoleModalActive=!0),this.updateAvailableRoles(this.$page.doc.roles)},computed:Object(r.a)(Object(r.a)(Object(r.a)({},Object(a.c)(["roleButtonText","operatorToken"])),Object(a.e)({role:function(e){return e.role.role},hasRoleChoiceBeenGiven:function(e){return e.role.hasRoleChoiceBeenGiven}})),{},{isRoleModalActive:{get:function(){return this.$store.state.role.isRoleModalActive},set:function(e){this.$store.commit("setRoleModalActive",e)}},links:function(){var e=this;var t=this.$static.allDocPage.edges.map((function(e){return e.node})).map((function(t){return Object(r.a)(Object(r.a)({},t),{},{availableForRole:(n=t.roles,o=e.role,""===o||0===n.length&&"OPERATOR"===o||-1!==n.indexOf(o))});var n,o})),n=new Set(t.map((function(e){return e.topic}))),o=(new Set(t.map((function(e){return e.type}))),new Map(l.a.topic.map((function(e,t){return[e,t]})))),a=new Map(l.a.type.map((function(e,t){return[e,t]}))),c=function(e){var t,n=0;if(0===e.length)return n;for(t=0;t1?arguments[1]:void 0)}}),r("includes")},z32d:function(e,t,n){}}]); \ No newline at end of file +(window.webpackJsonp=window.webpackJsonp||[]).push([[4],{Bo5W:function(e,t,n){"use strict";n("z32d")},DQNa:function(e,t,n){var o=n("busE"),i=Date.prototype,r=i.toString,a=i.getTime;new Date(NaN)+""!="Invalid Date"&&o(i,"toString",(function(){var e=a.call(this);return e==e?r.call(this):"Invalid Date"}))},I1kV:function(e,t,n){},TeQF:function(e,t,n){"use strict";var o=n("I+eb"),i=n("tycR").filter,r=n("Hd5f"),a=n("rkAj"),c=r("filter"),l=a("filter");o({target:"Array",proto:!0,forced:!c||!l},{filter:function(e){return i(this,e,arguments.length>1?arguments[1]:void 0)}})},ToJy:function(e,t,n){"use strict";var o=n("I+eb"),i=n("HAuM"),r=n("ewvW"),a=n("0Dky"),c=n("pkCn"),l=[],s=l.sort,p=a((function(){l.sort(void 0)})),d=a((function(){l.sort(null)})),u=c("sort");o({target:"Array",proto:!0,forced:p||!d||!u},{sort:function(e){return void 0===e?s.call(r(this)):s.call(r(this),i(e))}})},Tskq:function(e,t,n){"use strict";var o=n("bWFh"),i=n("ZWaQ");e.exports=o("Map",(function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}}),i)},dDYI:function(e,t,n){"use strict";n.r(t);n("TeQF"),n("yq1k"),n("yXV3"),n("2B1R"),n("ToJy"),n("DQNa"),n("Tskq"),n("07d7"),n("JfAA"),n("YGK4"),n("PKPk"),n("3bBZ");var o=n("VPjN"),i=n("0P+p"),r=n("8/MJ"),a=n("L2JU"),c=n("x2p9"),l=n.n(c),s={methods:{choose:function(e){this.$parent.$emit("input",e),this.$parent.close()}}},p=(n("Bo5W"),n("7uw+")),d={components:{RoleSelection:Object(p.a)(s,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"role-selection card"},[n("div",{staticClass:"card-content content"},[n("h1",[e._v("Who is the user of your product?")]),e._m(0),n("div",{staticClass:"choices"},[n("button",{staticClass:"button is-role",on:{click:function(t){return e.choose("THIRD_PARTY_DEVELOPER")}}},[e._v("Subscribers")]),n("span",[e._v("I'm making a product for subscribers")]),n("button",{staticClass:"button is-role",on:{click:function(t){return e.choose("OPERATOR")}}},[e._v("Telecom operators")]),n("span",[e._v("I'm making a product for telecom operators")]),n("button",{staticClass:"button is-role",on:{click:function(t){return e.choose("")}}},[e._v("No customisation")]),n("span",[e._v("Don't make any customisations to the content")])])])])}),[function(){var e=this.$createElement,t=this._self._c||e;return t("p",[this._v("\n We can customise the content to help you better achieve your goals.\n "),t("br"),this._v("You can change this later.\n ")])}],!1,null,null,null).exports},watch:{"$page.doc.roles":function(e){this.updateAvailableRoles(e)}},methods:Object(r.a)({},Object(a.b)(["updateRole","updateAvailableRoles"])),mounted:function(){this.hasRoleChoiceBeenGiven||this.isRoleModalActive||""!==this.role||(this.isRoleModalActive=!0),this.updateAvailableRoles(this.$page.doc.roles)},computed:Object(r.a)(Object(r.a)(Object(r.a)({},Object(a.c)(["roleButtonText","operatorToken"])),Object(a.e)({role:function(e){return e.role.role},hasRoleChoiceBeenGiven:function(e){return e.role.hasRoleChoiceBeenGiven}})),{},{isRoleModalActive:{get:function(){return this.$store.state.role.isRoleModalActive},set:function(e){this.$store.commit("setRoleModalActive",e)}},links:function(){var e=this;var t=this.$static.allDocPage.edges.map((function(e){return e.node})).map((function(t){return Object(r.a)(Object(r.a)({},t),{},{availableForRole:(n=t.roles,o=e.role,""===o||0===n.length&&"OPERATOR"===o||-1!==n.indexOf(o))});var n,o})),n=new Set(t.map((function(e){return e.topic}))),o=(new Set(t.map((function(e){return e.type}))),new Map(l.a.topic.map((function(e,t){return[e,t]})))),a=new Map(l.a.type.map((function(e,t){return[e,t]}))),c=function(e){var t,n=0;if(0===e.length)return n;for(t=0;t1?arguments[1]:void 0)}}),r("includes")},z32d:function(e,t,n){}}]); \ No newline at end of file diff --git a/call-forwarding/call-forwarding-api-reference/index.html b/call-forwarding/call-forwarding-api-reference/index.html index 3dc7a123..cfe1277f 100644 --- a/call-forwarding/call-forwarding-api-reference/index.html +++ b/call-forwarding/call-forwarding-api-reference/index.html @@ -1,7 +1,7 @@ - Call forwarding API reference - WGTWO API v0 docs + Call forwarding API reference - WGTWO API v0 docs