Exemplo n.º 1
0
        override public void Execute()
        {
            DocumentPackage superDuperPackage = PackageBuilder.NewPackageNamed(PackageName)
                                                .DescribedAs("This is a package created using the eSignLive SDK")
                                                .WithSigner(SignerBuilder.NewSignerWithEmail(email1)
                                                            .WithFirstName(FIRST_NAME)
                                                            .WithLastName(LAST_NAME)
                                                            .WithCustomId(signerId)
                                                            .ChallengedWithKnowledgeBasedAuthentication(
                                                                SignerInformationForEquifaxUSABuilder.NewSignerInformationForEquifaxUSA()
                                                                .WithFirstName(FIRST_NAME)
                                                                .WithLastName(LAST_NAME)
                                                                .WithStreetAddress(STREET_ADDRESS)
                                                                .WithCity(CITY)
                                                                .WithState(STATE)
                                                                .WithZip(ZIP)
                                                                .WithTimeAtAddress(TIME_AT_ADDRESS)
                                                                .WithSocialSecurityNumber(SOCIAL_SECURITY_NUMBER)
                                                                .WithHomePhoneNumber(HOME_PHONE_NUMBER)
                                                                .WithDateOfBirth(DATE_OF_BIRTH)
                                                                .WithDriversLicenseNumber(DRIVERS_LICENSE_NUMBER)
                                                                .Build()))
                                                .WithDocument(DocumentBuilder.NewDocumentNamed(documentName)
                                                              .FromStream(fileStream1, DocumentType.PDF)
                                                              .WithSignature(SignatureBuilder.SignatureFor(email1)
                                                                             .Build())
                                                              .Build())
                                                .Build();

            packageId = ossClient.CreateAndSendPackage(superDuperPackage);

            retrievedPackage = ossClient.GetPackage(packageId);
        }
Exemplo n.º 2
0
        public void BuildWithSpecificValues()
        {
            SignerInformationForEquifaxUSA signerInformationForEquifaxUSA = SignerInformationForEquifaxUSABuilder.NewSignerInformationForEquifaxUSA()
                                                                            .WithFirstName(firstName)
                                                                            .WithLastName(lastName)
                                                                            .WithStreetAddress(streetAddress)
                                                                            .WithCity(city)
                                                                            .WithState(state)
                                                                            .WithZip(zip)
                                                                            .WithSocialSecurityNumber(socialSecurityNumber)
                                                                            .WithHomePhoneNumber(homePhoneNumber)
                                                                            .WithDateOfBirth(dateOfBirth)
                                                                            .WithTimeAtAddress(timeAtAddress)
                                                                            .WithDriversLicenseNumber(driversLicenseNumber)
                                                                            .Build();

            Assert.AreEqual(firstName, signerInformationForEquifaxUSA.FirstName);
            Assert.AreEqual(lastName, signerInformationForEquifaxUSA.LastName);
            Assert.AreEqual(streetAddress, signerInformationForEquifaxUSA.StreetAddress);
            Assert.AreEqual(city, signerInformationForEquifaxUSA.City);
            Assert.AreEqual(state, signerInformationForEquifaxUSA.State);
            Assert.AreEqual(zip, signerInformationForEquifaxUSA.Zip);
            Assert.AreEqual(socialSecurityNumber, signerInformationForEquifaxUSA.SocialSecurityNumber);
            Assert.AreEqual(homePhoneNumber, signerInformationForEquifaxUSA.HomePhoneNumber);
            Assert.AreEqual(dateOfBirth, signerInformationForEquifaxUSA.DateOfBirth);
            Assert.AreEqual(timeAtAddress, signerInformationForEquifaxUSA.TimeAtAddress);
            Assert.AreEqual(driversLicenseNumber, signerInformationForEquifaxUSA.DriversLicenseNumber);
        }
Exemplo n.º 3
0
        override public void Execute()
        {
            Stream file = File.OpenRead(new FileInfo(Directory.GetCurrentDirectory() + "/src/document.pdf").FullName);

            DocumentPackage superDuperPackage = PackageBuilder.NewPackageNamed("SignerInformationForEquifaxUSAExample: " + DateTime.Now)
                                                .DescribedAs("This is a package created using the e-SignLive SDK")
                                                .WithSigner(SignerBuilder.NewSignerWithEmail(SIGNER_EMAIL)
                                                            .WithFirstName(FIRST_NAME)
                                                            .WithLastName(LAST_NAME)
                                                            .WithCustomId(signerId)
                                                            .ChallengedWithKnowledgeBasedAuthentication(
                                                                SignerInformationForEquifaxUSABuilder.NewSignerInformationForEquifaxUSA()
                                                                .WithFirstName(FIRST_NAME)
                                                                .WithLastName(LAST_NAME)
                                                                .WithStreetAddress(STREET_ADDRESS)
                                                                .WithCity(CITY)
                                                                .WithState(STATE)
                                                                .WithZip(ZIP)
                                                                .WithTimeAtAddress(TIME_AT_ADDRESS)
                                                                .WithSocialSecurityNumber(SOCIAL_SECURITY_NUMBER)
                                                                .WithHomePhoneNumber(HOME_PHONE_NUMBER)
                                                                .WithDateOfBirth(DATE_OF_BIRTH)
                                                                .WithDriversLicenseNumber(DRIVERS_LICENSE_NUMBER)
                                                                .Build()))
                                                .WithDocument(DocumentBuilder.NewDocumentNamed(documentName)
                                                              .FromStream(file, DocumentType.PDF)
                                                              .WithSignature(SignatureBuilder.SignatureFor(SIGNER_EMAIL)
                                                                             .Build())
                                                              .Build())
                                                .Build();

            packageId = eslClient.CreateAndSendPackage(superDuperPackage);

            retrievedPackage = eslClient.GetPackage(packageId);
        }
Exemplo n.º 4
0
 public SignerBuilder ChallengedWithKnowledgeBasedAuthentication(
     SignerInformationForEquifaxUSABuilder signerInformationForEquifaxUSABuilder)
 {
     return(ChallengedWithKnowledgeBasedAuthentication(signerInformationForEquifaxUSABuilder.Build()));
 }
Exemplo n.º 5
0
        override public void Execute()
        {
            SIGNER_WITH_AUTHENTICATION_EQUIFAX_CANADA =
                SignerBuilder.NewSignerWithEmail(email1)
                .WithFirstName("Signer1")
                .WithLastName("Canada")
                .WithCustomId("SingerCanadaID")
                .ChallengedWithKnowledgeBasedAuthentication(
                    SignerInformationForEquifaxCanadaBuilder.NewSignerInformationForEquifaxCanada()
                    .WithFirstName("Signer1")
                    .WithLastName("lastNameCanada")
                    .WithStreetAddress("1111")
                    .WithCity("Montreal")
                    .WithProvince("QC")
                    .WithPostalCode("A1A1A1")
                    .WithTimeAtAddress(1)
                    .WithDriversLicenseNumber("Driver licence number")
                    .WithSocialInsuranceNumber("111222333")
                    .WithHomePhoneNumber("5141112222")
                    .WithDateOfBirth(new DateTime(1965, 1, 1)))
                .ChallengedWithQuestions(ChallengeBuilder.FirstQuestion("What's your favorite restaurant? (answer: Staffany)")
                                         .Answer("Staffany")
                                         .SecondQuestion("What sport do you play? (answer: hockey)")
                                         .Answer("hockey"))
                .Build();

            SIGNER_WITH_AUTHENTICATION_EQUIFAX_USA =
                SignerBuilder.NewSignerWithEmail(email2)
                .WithFirstName("Signer2")
                .WithLastName("USA")
                .WithCustomId("SignerUSAID")
                .ChallengedWithKnowledgeBasedAuthentication(
                    SignerInformationForEquifaxUSABuilder.NewSignerInformationForEquifaxUSA()
                    .WithFirstName("Singer2")
                    .WithLastName("lastNameUSA")
                    .WithStreetAddress("2222")
                    .WithCity("New York")
                    .WithState("NY")
                    .WithZip("65212")
                    .WithSocialSecurityNumber("222667098")
                    .WithHomePhoneNumber("8701116547")
                    .WithTimeAtAddress(3)
                    .WithDriversLicenseNumber("Driver License Number")
                    .WithDateOfBirth(new DateTime(1967, 2, 2)))
                .ChallengedWithQuestions(ChallengeBuilder.FirstQuestion("What's your favorite sport? (answer: golf)")
                                         .Answer("golf")
                                         .SecondQuestion("What music instrument do you play? (answer: drums)")
                                         .Answer("drums"))
                .Build();

            DocumentPackage superDuperPackage = PackageBuilder.NewPackageNamed(PackageName)
                                                .DescribedAs("This is a package created using the eSignLive SDK")
                                                .WithSigner(SIGNER_WITH_AUTHENTICATION_EQUIFAX_CANADA)
                                                .WithSigner(SIGNER_WITH_AUTHENTICATION_EQUIFAX_USA)
                                                .WithDocument(DocumentBuilder.NewDocumentNamed(documentName)
                                                              .FromStream(fileStream1, DocumentType.PDF)
                                                              .WithSignature(SignatureBuilder.SignatureFor(email1)
                                                                             .Build())
                                                              .WithSignature(SignatureBuilder.SignatureFor(email2)
                                                                             .Build())
                                                              .Build())
                                                .Build();

            packageId = ossClient.CreateAndSendPackage(superDuperPackage);

            retrievedPackage = ossClient.GetPackage(packageId);
        }
        private Silanis.ESL.SDK.SignerInformationForEquifaxUSA CreateTypicalSDKSignerInformationForEquifaxUSA()
        {
            Silanis.ESL.SDK.SignerInformationForEquifaxUSA SignerInformationForEquifaxUSA = SignerInformationForEquifaxUSABuilder.NewSignerInformationForEquifaxUSA()
                                                                                            .WithFirstName("Signer First Name")
                                                                                            .WithLastName("Last Name")
                                                                                            .WithStreetAddress("main street")
                                                                                            .WithCity("Montreal")
                                                                                            .WithState("Quebec")
                                                                                            .WithZip("H4L3K1")
                                                                                            .WithSocialSecurityNumber("111-222-333-444")
                                                                                            .WithHomePhoneNumber("1-800-123-8763")
                                                                                            .WithDateOfBirth(new DateTime())
                                                                                            .WithDriversLicenseNumber("98826278262728262")
                                                                                            .WithTimeAtAddress(2)
                                                                                            .Build();

            return(SignerInformationForEquifaxUSA);
        }