mirror of
https://github.com/kevin-DL/services.git
synced 2026-01-11 19:04:35 +00:00
Merge branch 'master' of ssh://github.com/micro/services
This commit is contained in:
@@ -16,7 +16,7 @@ type EventService struct {
|
||||
client *client.Client
|
||||
}
|
||||
|
||||
// Publish a message to the event. Specify a topic to group messages for a specific topic.
|
||||
// Publish a message to the event stream.
|
||||
func (t *EventService) Publish(request *PublishRequest) (*PublishResponse, error) {
|
||||
rsp := &PublishResponse{}
|
||||
return rsp, t.client.Call("event", "Publish", request, rsp)
|
||||
|
||||
@@ -77,5 +77,5 @@
|
||||
"prepare": "npm run build"
|
||||
},
|
||||
"types": "index.d.ts",
|
||||
"version": "1.0.610"
|
||||
"version": "1.0.611"
|
||||
}
|
||||
@@ -7,7 +7,7 @@ import (
|
||||
"github.com/micro/services/clients/go/event"
|
||||
)
|
||||
|
||||
// Publish a message to the event. Specify a topic to group messages for a specific topic.
|
||||
// Publish a message to the event stream.
|
||||
func PublishAmessage() {
|
||||
eventService := event.NewEventService(os.Getenv("MICRO_API_TOKEN"))
|
||||
rsp, err := eventService.Publish(&event.PublishRequest{
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
const { EventService } = require("m3o/event");
|
||||
|
||||
// Publish a message to the event. Specify a topic to group messages for a specific topic.
|
||||
// Publish a message to the event stream.
|
||||
async function publishAmessage() {
|
||||
let eventService = new EventService(process.env.MICRO_API_TOKEN);
|
||||
let rsp = await eventService.publish({
|
||||
|
||||
Reference in New Issue
Block a user