The service allows searching for app item signatures as well as creating signature drafts to store data before issuing a signature.

Hierarchy

  • EntitySigns

Methods

createDraft

  • Creates a draft of an app item signature.

    The method creates a signature draft. It is used to store data before the signature is issued. To create a signature draft, pass the following parameters: — External ID of the signature obtained from the provider. It is used to get detailed information about the signature on the provider’s side. — Digital signature ID. — Reference object with a link to the item of an arbitrary app that needs to be signed. — Internal footprint of data that is being signed, for example, the file’s hash. —Signature type that determines what needs to be signed: the attributes, the file, or both.
    Example:

     const comment = 'some comment';
    // The singing  function in the external provider is called 
    // The name  `createSignInExternalProvider` is given as an example 
    const issueId = await  createSignInExternalProvider(); 
    // ID of the digital signature that is used  for signing 
    // This ID is extracted from the context 
    const digitalSignId =  Context.data.digitalSignId; 
    // A link to the app item that is being signed  in extracted from the context 
    // This can be done using search 
    const item  = Context.data.app; 
    // Internal signatures of the app item 
    const innerSign  = await Context.data.app.getDataSigns(); 
    // The app item’s update time  extracted from its attributes 
    const entityUpdateDate = Context.data.app.data .__updatedAt; 
    // Signature type: attributes or file 
    const t = Context.data. type; 
    // Digital signature provider 
    const provider = await System.providers .search().where(f => f.code.eq('<some code>')).first(); 
    const entitySign =  await System.signs.entitySigns.createDraft( 
      issueId, 
      digitalSignId, 
       item, 
      innerSign, 
      entityUpdateDate, 
      t, 
      comment, 
      provider, 
    );  
    
    deprecated

    Use createDraft with the Signature update time parameter of the TDatetime type or with the Digital signature provider object parameter of the SignProviderItem type.

    Parameters

    • issueId: string

      External ID of the signature issued by the provider.

    • digitalSignId: string

      Digital signature ID.

    • item: RefItem

      Reference object to an arbitrary app item.

    • innerSign: SignData[]

      Internal data footprint.

    • entityUpdateDate: string

      Signature update time.

    • type: SignType

      Signature type: attributes, file, or both.

    • comment: string

      Comment about the issuing of the signature or about the refusal to sign.

    • provider: SignProvider

      Digital signature provider object.

    Returns Promise<EntitySignItem>

    Object used to make search queries to search for app item signatures.

  • Creates a draft of an app item signature.

    The method creates a signature draft. It is used to store data before the signature is issued. To create a signature draft, pass the following parameters: — External ID of the signature obtained from the provider. It is used to get detailed information about the signature on the provider’s side. — Digital signature ID. — Reference object with a link to the item of an arbitrary app that needs to be signed. — Internal footprint of data that is being signed, for example, the file’s hash. —Signature type that determines what needs to be signed: the attributes, the file, or both.
    Example:

     const comment = 'some comment';
    // The singing  function in the external provider is called 
    // The name  `createSignInExternalProvider` is given as an example 
    const issueId = await  createSignInExternalProvider(); 
    // ID of the digital signature that is used  for signing 
    // This ID is extracted from the context 
    const digitalSignId =  Context.data.digitalSignId; 
    // A link to the app item that is being signed  in extracted from the context 
    // This can be done using search 
    const item  = Context.data.app; 
    // Internal signatures of the app item 
    const innerSign  = await Context.data.app.getDataSigns(); 
    // The app item’s update time  extracted from its attributes 
    const entityUpdateDate = Context.data.app.data .__updatedAt; 
    // Signature type: attributes or file 
    const t = Context.data. type; 
    // Digital signature provider 
    const provider = await System.providers .search().where(f => f.code.eq('<some code>')).first(); 
    const entitySign =  await System.signs.entitySigns.createDraft( 
      issueId, 
      digitalSignId, 
       item, 
      innerSign, 
      entityUpdateDate, 
      t, 
      comment, 
      provider, 
    );  
    

    Parameters

    • issueId: string

      External ID of the signature issued by the provider.

    • digitalSignId: string

      Digital signature ID.

    • item: RefItem

      Reference object to an arbitrary app item.

    • innerSign: SignData[]

      Internal data footprint.

    • entityUpdateDate: TDatetime

      Signature update time.

    • type: SignType

      Signature type: attributes, file, or both.

    • comment: string

      Comment about the issuing of the signature or about the refusal to sign.

    • provider: SignProviderItem

      Digital signature provider object.

    Returns Promise<EntitySignItem>

    Object used to make search queries to search for app item signatures.

search

  • The method is used to search for signatures of an app item.

    You can use this method to:

    • Filter signatures using different parameters.
    • Search for signatures and get specific or first items from the search results.
    • Sort search results.
    • Limit the number of search results or see search results on several pages. Example:
      const  entitySign = await System.signs.entitySigns.search().where(f => f.__id.eq( '<some id>')).first();
      

    Returns EntitySignSearch

    Object used to make search queries to search for signatures.