adaojunior / pusher Goto Github PK
View Code? Open in Web Editor NEWThe Dart library for interacting with the Pusher HTTP API.
Home Page: https://pub.dartlang.org/packages/pusher
License: MIT License
The Dart library for interacting with the Pusher HTTP API.
Home Page: https://pub.dartlang.org/packages/pusher
License: MIT License
IS there a way around this? I am using a private channel
/Users/rlwt/Downloads/flutter/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_pusher-1.0.1/android/src/main/java/com/ninjasolutions/pusher/PusherPlugin.java:382: error: cannot find symbol
channel.trigger(eventName, "{}");
^
symbol: method trigger(String,String)
location: variable channel of type Channel
1 error
FAILURE: Build failed with an exception.
Compilation failed; see the compiler error output for details.
Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
Get more help at https://help.gradle.org
BUILD FAILED in 40s
Exception: Gradle task assembleDebug failed with exit code 1
part of pusher;
class PusherException implements Exception {
/// Error message
final String message;
PusherException(this.message);
/// Error message
String toString() => message;
}
class RequestException extends PusherException {
/// Request URL
final Uri url;
/// Request status code
final int statusCode;
/// Response body, if received
final String body;
RequestException(String message,this.url, this.statusCode,[this.body]) : super(message);
}
Hi,
having a class User in the pusher package clashes very often with app specific User classes when not prefixing on import. How about a PusherUser as name for that?
How do I subscribe my client to an event channel and listen for when the channel is triggered?
This is the javascript example:
const pusher = new Pusher('<pusher api key>', {
cluster: 'cluster',
authEndpoint: 'https://test-api.com/test-endpoint',
auth: {
headers: {
'authorization': `Bearer ${token}`
}
}
});
const channel = pusher.subscribe(`test_channel`);
channel.bind('news', function(data) {
console.log(data);
});
How would I do this auth and binding and subscription with this library in flutter, please?
Pusher pusher = new Pusher(
'PUSHER_APP_ID',
'PUSHER_APP_KEY',
'PUSHER_APP_SECRET',
encrypted: true,
port: 1727
);
await pusher.trigger(
['test_channel'],
' my_event',
data,
socketId: '74124.3251944'
);
I'm trying to use this package in a Flutter test app but I'm getting an 'Unknow auth_key' response - after some googling I found out this is because of the cluster
setting which seems unsupported in this library...
Any known way to fix this?
Can you subscribe to a channel and listen to events with this library
I'm looking at using this package in my server, but I don't see Beams support. Is there any?
Are you still willing to maintain this project? I'm interested in using it and possibly helping work on the code.
How much work would it require to migrate this to Dart 2?
new Pusher.useApplicationDefaultCredentials()
should use env variables to create the pusher client out of the box.
User user = new User(1); /// should be possible
HandshakeException: Handshake error in client (OS Error:
CERTIFICATE_VERIFY_FAILED: ok(handshake.cc:354))
is there any configuration that I need to do on client side ?
can we have a badCertificateCallback like in HttpClient ?
static HttpClient client = new HttpClient()
..badCertificateCallback = (_certificateCheck);
static bool _certificateCheck(X509Certificate cert, String host, int port) =>
host == 'local.domain.ext';
Hi.
I want to use ChatKit from pusher.com in a flutter app and I am not sure where to start from. From what I can see, this package has support only for channels. Is that right?
Can you point me in the right direction? Thank you.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.