@welshare/sdk
    Preparing search index...
    • todo: #91 add more fields, think of how to specify canonical urls todo: validate against the actual fhir questionnaire!

      adds uuid, timestamp, wraps into array. Sets fhir fields by our uids. side effect: validates the submission

      Parameters

      • submission: {
            author?: {
                display?: string;
                id?: string;
                identifier?: { system?: string; value?: string };
                reference?: string;
                type?: string;
            };
            authored?: string;
            id?: string;
            item: {
                answer?: any[];
                definition?: string;
                id?: string;
                item?: any[];
                linkId: string;
                text?: string;
            }[];
            meta?: { profile?: string[]; tag?: { code?: string; system?: string }[] };
            questionnaire: string;
            resourceType: "QuestionnaireResponse";
            source?: {
                display?: string;
                id?: string;
                identifier?: { system?: string; value?: string };
                reference?: string;
                type?: string;
            };
            status: | "entered-in-error"
            | "in-progress"
            | "completed"
            | "amended"
            | "stopped";
            subject?: {
                display?: string;
                id?: string;
                identifier?: { system?: string; value?: string };
                reference?: string;
                type?: string;
            };
        }

        QuestionnaireResponseSubmission the raw submission data

      • controllerDID: string

        string the user that submitted the data

      • applicationId: string

        the app that submitted the data

      • OptionalsocialShares: InterpolateSocials

        InterpolateSocials fields to be interpolated into the submission

      Returns {
          _id: string;
          author: {
              display?: string;
              id?: string;
              identifier?: { system?: string; value?: string };
              reference?: string;
              type?: string;
          };
          authored: string;
          id?: string;
          item: {
              answer?: any[];
              definition?: string;
              id?: string;
              item?: any[];
              linkId: string;
              text?: string;
          }[];
          meta?: { profile?: string[]; tag?: { code?: string; system?: string }[] };
          questionnaire: string;
          resourceType: "QuestionnaireResponse";
          source: {
              display?: string;
              id?: string;
              identifier?: { system?: string; value?: string };
              reference?: string;
              type?: string;
          };
          status: | "entered-in-error"
          | "in-progress"
          | "completed"
          | "amended"
          | "stopped";
          subject: {
              display?: string;
              id?: string;
              identifier?: { system?: string; value?: string };
              reference?: string;
              type?: string;
          };
      }[]

      Array insertable nillion data