aboutsummaryrefslogtreecommitdiffstats
path: root/pygithub3/requests/git_data/blobs.py
blob: a4bddd6512d2d940359aeb3d40b81585cdde880d (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
# -*- encoding: utf-8 -*-

from pygithub3.requests.base import Request
from pygithub3.resources.git_data import Blob


class Get(Request):
    uri = 'repos/{user}/{repo}/git/blobs/{sha}'
    resource = Blob


class Create(Request):
    uri = 'repos/{user}/{repo}/git/blobs'
    resource = Blob
    body_schema = {
        'schema': ('content', 'encoding'),
        'required': ('content', 'encoding'),  # TODO: is enc really required?
    }