title: Django Serializers many to many relationship
body: <p>I am working in a small project using Angularjs and Django. I have two different models with its corresponding end points.</p>
  
  <pre><code>class Skills(models.Model):
      skills = models.CharField(max_length=100)
  
      def __str__(self):
          return self.skills
  
  
  
    class Project(models.Model):
  ...
      required_skills = models.ManyToManyField(
              Skills, verbose_name="list of skills")
  ..
  </code></pre>
  
  <p>This is a copy of my skills end point</p>
  
  <pre><code>[
      {
          "id": 1,
          "skills": "Css"
      },
      {
          "id": 2,
          "skills": "HTML5"
      },
      {
          "id": 3,
          "skills": "Java"
      }
  ]
  </code></pre>
  
  <p>On the front page I have a form that uses $http.post service to send data to the database. When I project is created, it might require one skill or multiple skills. Here is where my confusion come, I can store I foreign key by sending the pk which in this case is id. However, since I am dealing with a many to many relationship, I can not figure out what is the best way to proceed. I have read the documentation and some online resources with any success. Also, the form has an dropdown menu with the list of skills.I got this values using $http.get. Please anyone has any idea of how to solve this issue? </p>
  
  <p><a href="http://www.django-rest-framework.org/api-guide/relations/" rel="nofollow noreferrer">http://www.django-rest-framework.org/api-guide/relations/</a>
  <a href="https://stackoverflow.com/questions/17935638/serializing-manytomany-in-django-rest-framework-2-3-5-throws-valueerror">Serializing ManyToMany in Django Rest Framework (2.3.5) throws ValueError</a></p>