improvement of a database register function
You can actually merge them pretty easily. They're very similar, with just a minor difference in the strings that determine what key failed. But luckily you can get the bad key by using the message attribute of the exception:]

try:                                                                        
    site_id = request.data['site_id']                                       
    category_id = request.data['category_id']                               
except Exception as e:                                                      
    print('Request error or missing {}:'.format(e.message), e)                           
    return Response(status=status.HTTP_400_BAD_REQUEST)                     


Now they both work the same except that the missing key is taken out of your exception e and formatted into the message you print for the user. 

I also think you should except KeyError, not just any old Exception. Using the latter would mask typos, while the former deals specifically with the typeof exception you expect to appear.