added api packet assembling function