syntax = "proto3";

package nominal.conjure.v1;

import "google/protobuf/descriptor.proto";

option java_multiple_files = true;
option java_package = "io.nominal.conjure.v1";

extend google.protobuf.MessageOptions {
  ConjureCompatibility conjure_compat = 54052;
}

extend google.protobuf.FieldOptions {
  ConjureFieldCompatibility conjure_field_compat = 54053;
}


// Options that control Protobuf to Conjure transcoding compatibility.
message ConjureCompatibility {
  // Marks a message as a Conjure Union type. This allows Protobuf > JSON transcoding to emit JSON that adheres to the
  // [Conjure Union wire format](https://github.com/palantir/conjure/blob/master/docs/spec/wire.md#54-union-json-format).
  bool union_message = 1;

}

// Options that control Protobuf to Conjure transcoding compatibility.
message ConjureFieldCompatibility {
  // Denotes that the field is a map value that was wrapped for Protobuf, and should be unwrapped for Conjure compatibility.
  bool map_value_wrapper = 1;
}
