# Generated by Django 2.1.1 on 2018-09-25 21:12

from django.db import migrations, models
import django.db.models.deletion
import jsonfield.fields


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Endpoint',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('method', models.CharField(choices=[('GET', 'GET'), ('HEAD', 'HEAD'), ('POST', 'POST'), ('PUT', 'PUT'), ('PATCH', 'PATCH'), ('DELETE', 'DELETE'), ('CONNECT', 'CONNECT'), ('OPTIONS', 'OPTIONS'), ('TRACE', 'TRACE')], default='GET', max_length=8)),
                ('path', models.CharField(help_text='The relative path of the url as a regular expression, i.e. /post/\\d/', max_length=128)),
                ('parameters', jsonfield.fields.JSONField(blank=True, help_text='Enter request parameters as a json map')),
                ('require_authentication', models.BooleanField(default=False)),
                ('explanation', models.TextField(blank=True, help_text='Describe this endpoint for other administrators of django-mock-rest')),
            ],
        ),
        migrations.CreateModel(
            name='Response',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('weight', models.PositiveIntegerField(default=1)),
                ('status', models.PositiveSmallIntegerField(choices=[(200, '200 OK'), (201, '201 Created'), (204, '204 No content'), (301, '301 Moved permanently'), (304, '304 Not modified'), (307, '307 Temporary redirect'), (400, '400 Bad request'), (401, '401 Unauthorized'), (403, '403 Forbidden'), (404, '404 Not found'), (409, '409 Conflict'), (500, '500 Internal server error'), (501, '501 Not implemented'), (999, 'Timeout (no response)')], default=200)),
                ('data', jsonfield.fields.JSONField(blank=True, help_text='Enter a static json response')),
                ('endpoint', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='responses', to='django_mock_rest.Endpoint')),
            ],
        ),
    ]
