How does the Smart Contracts work in a blockchain
when it comes to bitcoin world, smart contracts are usually some kind of escrow service. A good reference is in the book from Andreas: "Mastering Bitcoin". Both editions can be found in the net. The second edition has chapter "7. Advanced Transactions and Scripting". It explains the use of multisig, escrow, timelocks and more. 

When you say integration in blockchain technology, then in this case it is bitcoin and its scripting. One of the several use case examples from the book is this: 


  ... The participants in the multisig scheme are Mohammed, his two
  partners Saeed and Zaira, and their company lawyer Abdul. The three
  partners make decisions based on a majority rule, so two of the three
  must agree. However, in the case of a problem with their keys, they
  want their lawyer to be able to recover the funds with one of the
  three partner signatures. Finally, if all partners are unavailable or
  incapacitated for a while, they want the lawyer to be able to manage
  the account directly.


I would also like to mention, that the logic behind these scripts is the secret to the lightning network. 
Have a good reading :-)