const require_rolldown_runtime = require('../../../../../../_virtual/rolldown_runtime.js');
const require_index = require('../../../../../../node_modules/.pnpm/class-transformer@0.5.1/node_modules/class-transformer/cjs/index.js');
const require_index$1 = require('../../../../../../node_modules/.pnpm/class-validator@0.14.1/node_modules/class-validator/cjs/index.js');
const require_decorateMetadata = require('../../../../../../_virtual/_@oxc-project_runtime@0.94.0/helpers/decorateMetadata.js');
const require_decorate = require('../../../../../../_virtual/_@oxc-project_runtime@0.94.0/helpers/decorate.js');
const require_messageType = require('../../../util/messageType.js');
const require_DidCommMessage = require('../../../DidCommMessage.js');
const require_SignatureDecorator = require('../../../decorators/signature/SignatureDecorator.js');

//#region ../didcomm/src/modules/connections/messages/DidCommConnectionResponseMessage.ts
var import_cjs = /* @__PURE__ */ require_rolldown_runtime.__toESM(require_index.require_cjs());
var import_cjs$1 = /* @__PURE__ */ require_rolldown_runtime.__toESM(require_index$1.require_cjs());
var _ref;
/**
* Message part of connection protocol used to complete the connection
*
* @see https://github.com/hyperledger/aries-rfcs/blob/master/features/0160-connection-protocol/README.md#2-connection-response
*/
var DidCommConnectionResponseMessage = class DidCommConnectionResponseMessage extends require_DidCommMessage.DidCommMessage {
	/**
	* Create new ConnectionResponseMessage instance.
	* @param options
	*/
	constructor(options) {
		super();
		this.allowDidSovPrefix = true;
		this.type = DidCommConnectionResponseMessage.type.messageTypeUri;
		if (options) {
			this.id = options.id || this.generateId();
			this.connectionSig = options.connectionSig;
			this.setThread({ threadId: options.threadId });
		}
	}
};
DidCommConnectionResponseMessage.type = require_messageType.parseMessageType("https://didcomm.org/connections/1.0/response");
require_decorate.__decorate([require_messageType.IsValidMessageType(DidCommConnectionResponseMessage.type), require_decorateMetadata.__decorateMetadata("design:type", Object)], DidCommConnectionResponseMessage.prototype, "type", void 0);
require_decorate.__decorate([
	(0, import_cjs.Type)(() => require_SignatureDecorator.SignatureDecorator),
	(0, import_cjs$1.ValidateNested)(),
	(0, import_cjs$1.IsInstance)(require_SignatureDecorator.SignatureDecorator),
	(0, import_cjs.Expose)({ name: "connection~sig" }),
	require_decorateMetadata.__decorateMetadata("design:type", typeof (_ref = typeof require_SignatureDecorator.SignatureDecorator !== "undefined" && require_SignatureDecorator.SignatureDecorator) === "function" ? _ref : Object)
], DidCommConnectionResponseMessage.prototype, "connectionSig", void 0);

//#endregion
exports.DidCommConnectionResponseMessage = DidCommConnectionResponseMessage;