GRPC Append Request

I’m trying to do some analysis to work on a Python client based on the newly supported GRPC protocol.

Right now I’m trying to understand how an Append Request works:

message AppendReq {
	oneof content {
		Options options = 1;
		ProposedMessage proposed_message = 2;
	}

	message Options {
		event_store.client.shared.StreamIdentifier stream_identifier = 1;
		oneof expected_stream_revision {
			uint64 revision = 2;
			event_store.client.shared.Empty no_stream = 3;
			event_store.client.shared.Empty any = 4;
			event_store.client.shared.Empty stream_exists = 5;
		}
	}
	message ProposedMessage {
		event_store.client.shared.UUID id = 1;
		map<string, string> metadata = 2;
		bytes custom_metadata = 3;
		bytes data = 4;
	}
}

It’s not clear to me, just looking at the proto: when should I send oneof options, and when the proposed_message?

Thank you :slight_smile:

Sorry for the (very) late response.

Append rpc call uses a stream as input. You send Options first then ProposedMessage