in Container object which we fetch we got this properties externalIdentifier=/carddav/v1/principals/garejakirit%40gmail.com/lists/default/
externalModificationTag="6bae89da88eb93cc.701"
externalSyncTag=https://www.googleapis.com/carddav/v1/synctoken/0802100118E4A18AF598E68B03220C08A4A886BE0610D8E2FA8701
so using externalIdentifier we can get gmail or any other email and if iCloud than a 64 letter unique code
and using this externalSyncTag we can get source if google than we got google api and if any other than that api so that's how we can determine the source of contact i did like this but is there any better way to do that please discuss here