Examples: query, "exact match", wildcard*, wild?ard, wild*rd
Fuzzy search: cake~ (finds cakes, bake)
Term boost: "red velvet"^4, chocolate^2
Field grouping: tags:(+work -"fun-stuff")
Escape special characters +-&|!(){}[]^"~*?:\ - e.g. \+ \* \!
Range search: properties.timestamp:[1587729413488 TO *] (inclusive), properties.title:{A TO Z}(excluding A and Z)
Combinations: chocolate AND vanilla, chocolate OR vanilla, (chocolate OR vanilla) NOT "vanilla pudding"
Field search: properties.title:"The Title" AND text
Back to post

Revisions 4

2 years ago
Yong Sheng Tan
39 × 2 Administrator
Send the file
Send the file
Sending and receiving messages is demonstrated numerous times in the BDK 2.0 courses. Please refer to the demos at the end of the chapters. Attachments are an optional field in the Message object, which accepts any type of InputStream. An example using `FileInputStream` would look like this: ```java // Java Attachment file = new Attachment(new FileInputStream("./data.csv"), "data.csv"); Message msg = Message.builder().attachments(List.of(file)).content("Hello").build(); bdk.messages().send(streamId, msg); ``` ```python # Python with open("data.csv", "rb") as file: await bdk.messages().send_message(stream_id, Message(content="Hello", attachments=[file])) ```
Sending and receiving messages is demonstrated numerous times in the BDK 2.0 courses. Please refer to the demos at the end of the chapters. Attachments are an optional field in the Message object, which accepts any type of InputStream. An example using `FileInputStream` would look like this: ```java // Java Attachment file = new Attachment(new FileInputStream("./data.csv"), "data.csv"); Message msg = Message.builder().attachments(List.of(file)).content("Hello").build(); bdk.messages().send(streamId, msg); ``` ```python with open("data.csv", "rb") as file: await bdk.messages().send_message(stream_id, Message(content="Hello", attachments=[file])) ```
2 years ago
Yong Sheng Tan
39 × 2 Administrator
Send the file
Send the file
Sending and receiving messages is demonstrated numerous times in the BDK 2.0 courses. Please refer to the demos at the end of the chapters. Attachments are an optional field in the Message object, which accepts any type of InputStream. An example using `FileInputStream` would look like this: ```java // Java Attachment file = new Attachment(new FileInputStream("./data.csv"), "data.csv"); Message msg = Message.builder().attachments(List.of(file)).content("Hello").build(); bdk.messages().send(streamId, msg); ``` ```python with open("data.csv", "rb") as file: await bdk.messages().send_message(stream_id, Message(content="Hello", attachments=[file])) ```
Sending and receiving messages is demonstrated numerous times in the BDK 2.0 for Java course. Please refer to the demos at the end of the chapters. Attachments are an optional field in the Message object, which accepts any type of InputStream. An example using `FileInputStream` would look like this: ```java Attachment file = new Attachment(new FileInputStream("./data.csv"), "data.csv"); Message msg = Message.builder().attachments(List.of(file)).content("Hello").build(); bdk.messages().send(streamId, msg); ```
2 years ago
Yong Sheng Tan
39 × 2 Administrator
Send the file
Send the file
Sending and receiving messages is demonstrated numerous times in the BDK 2.0 for Java course. Please refer to the demos at the end of the chapters. Attachments are an optional field in the Message object, which accepts any type of InputStream. An example using `FileInputStream` would look like this: ```java Attachment file = new Attachment(new FileInputStream("./data.csv"), "data.csv"); Message msg = Message.builder().attachments(List.of(file)).content("Hello").build(); bdk.messages().send(streamId, msg); ```
Sending and receiving messages is demonstrated numerous times in the BDK 2.0 for Java course. Please refer to the demos at the end of the chapters. Attachments are an optional field in the Message object, which accepts any type of InputStream. An example using `FileInputStream` would look like this: ```java Attachment file = new Attachment(new FileInputStream(new File("path/to/file.csv"))); Message msg = Message.builder().attachments(List.of(file)).content("Hello").build(); bdk.messages().send(streamId, msg); ```
2 years ago
Original
Yong Sheng Tan
39 × 2 Administrator
Send the file

Sending and receiving messages is demonstrated numerous times in the BDK 2.0 for Java course. Please refer to the demos at the end of the chapters. Attachments are an optional field in the Message object, which accepts any type of InputStream. An example using `FileInputStream` would look like this: ```java Attachment file = new Attachment(new FileInputStream(new File("path/to/file.csv"))); Message msg = Message.builder().attachments(List.of(file)).content("Hello").build(); bdk.messages().send(streamId, msg); ```