Insert a document with an expiration is via the sdk in couchbase 6.0

Hi
I am inserting records in couchbase buket using Azure ADF (couchbase ODBC driver). I have couchbase version 6.0.1.
Now requirement is to insert a document with an 21 days record expiration. I went thru so many articles over internet some suggesting with couchbase 6.0 we can do this via the sdk in couchbase.

Can anyone suggest where how to write SDK in couchbase and where (sample ). I am new to couchbase as well as Java.

Appreciate, if any other option also there then please suggest

Regards
Vikas

Hello @vikas_g14

Welcome to the Couchbase Community !

Are you using Java SDK 3.0 (or above) ?
Here is the documentation, hope it helps