Skip to content

Commit 8ba6e35

Browse files
Merge pull request #38 from apivideo/date-rage-required-in-analytics
feat(all) Date range param is required in analytics endpoints
2 parents de358b3 + c575423 commit 8ba6e35

File tree

8 files changed

+20
-17
lines changed

8 files changed

+20
-17
lines changed
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
fa7ac2451c4cf442853cb5c85c8372aa1c7969a3232442adf3109d7346edc5f2
1+
94990465713a14b6421dfb20f4a7e9ad69bcdc31aa22b7789aa907bbb3144304

ApiVideoUploader.podspec

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ Pod::Spec.new do |s|
44
s.osx.deployment_target = '10.12'
55
s.tvos.deployment_target = '10.0'
66
s.watchos.deployment_target = '3.0'
7-
s.version = '1.0.0'
8-
s.source = { :git => 'https://github.com/apivideo/api.video-ios-uploader', :tag => 'v1.0.0' }
7+
s.version = '1.0.1'
8+
s.source = { :git => 'https://github.com/apivideo/api.video-ios-uploader', :tag => 'v1.0.1' }
99
s.authors = { 'Ecosystem Team' => 'ecosystem@api.video' }
1010
s.license = { :type => 'MIT' }
1111
s.homepage = 'https://docs.api.video'

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
# Changelog
22
All changes to this project will be documented in this file.
33

4+
## [1.0.1] - 2022-09-13
5+
- period parameter is now mandatory in analytics endpoints
6+
47
## [1.0.0] - 2022-07-05
58
- Add SDK origin header
69

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,14 +39,14 @@ It allows you to upload videos in two ways:
3939
Specify it in your `Cartfile`:
4040

4141
```
42-
github "apivideo/api.video-ios-uploader" ~> 1.0.0
42+
github "apivideo/api.video-ios-uploader" ~> 1.0.1
4343
```
4444

4545
Run `carthage update`
4646

4747
### CocoaPods
4848

49-
Add `pod 'ApiVideoUploader', '1.0.0'` in your `Podfile`
49+
Add `pod 'ApiVideoUploader', '1.0.1'` in your `Podfile`
5050

5151
Run `pod install`
5252

Sources/APIs.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ enum ApiVideoUploaderError: Error {
1313
public class ApiVideoUploader {
1414
public static var apiKey: String? = nil
1515
public static var basePath = "https://ws.api.video"
16-
internal static var customHeaders:[String: String] = ["AV-Origin-Client": "ios-uploader:1.0.0"]
16+
internal static var customHeaders:[String: String] = ["AV-Origin-Client": "ios-uploader:1.0.1"]
1717
private static var chunkSize: Int = 50 * 1024 * 1024
1818
internal static var requestBuilderFactory: RequestBuilderFactory = AlamofireRequestBuilderFactory()
1919
internal static var credential = ApiVideoCredential()

Sources/APIs/AuthenticationAPI.swift

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import AnyCodable
1313
open class AuthenticationAPI {
1414

1515
/**
16-
Authenticate
16+
Advanced - Authenticate (1/2)
1717

1818
- parameter authenticatePayload: (body)
1919
- parameter apiResponseQueue: The queue on which api response is dispatched.
@@ -33,7 +33,7 @@ open class AuthenticationAPI {
3333

3434

3535
/**
36-
Authenticate
36+
Advanced - Authenticate (1/2)
3737
- POST /auth/api-key
3838
- To get started, submit your API key in the body of your request. api.video returns an access token that is valid for one hour (3600 seconds). A refresh token is also returned. View a [tutorial](https://api.video/blog/tutorials/authentication-tutorial) on authentication. All tutorials using the [authentication endpoint](https://api.video/blog/endpoints/authenticate)
3939
- parameter authenticatePayload: (body)
@@ -59,7 +59,7 @@ open class AuthenticationAPI {
5959

6060

6161
/**
62-
Refresh token
62+
Advanced - Refresh token (2/2)
6363

6464
- parameter refreshTokenPayload: (body)
6565
- parameter apiResponseQueue: The queue on which api response is dispatched.
@@ -79,7 +79,7 @@ open class AuthenticationAPI {
7979

8080

8181
/**
82-
Refresh token
82+
Advanced - Refresh token (2/2)
8383
- POST /auth/refresh
8484
- Use the refresh endpoint with the refresh token you received when you first authenticated using the api-key endpoint. Send the refresh token in the body of your request. The api.video API returns a new access token that is valid for one hour (3600 seconds) and a new refresh token.
8585
- parameter refreshTokenPayload: (body)

docs/AuthenticationAPI.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,16 @@ All URIs are relative to *https://ws.api.video*
44

55
Method | HTTP request | Description
66
------------- | ------------- | -------------
7-
[**authenticate**](AuthenticationAPI.md#postauthapikey) | **POST** /auth/api-key | Authenticate
8-
[**refresh**](AuthenticationAPI.md#postauthrefresh) | **POST** /auth/refresh | Refresh token
7+
[**authenticate**](AuthenticationAPI.md#postauthapikey) | **POST** /auth/api-key | Advanced - Authenticate (1/2)
8+
[**refresh**](AuthenticationAPI.md#postauthrefresh) | **POST** /auth/refresh | Advanced - Refresh token (2/2)
99

1010

1111
# **authenticate**
1212
```swift
1313
open class func authenticate(authenticatePayload: AuthenticatePayload, completion: @escaping (_ data: AccessToken?, _ error: Error?) -> Void)
1414
```
1515

16-
Authenticate
16+
Advanced - Authenticate (1/2)
1717

1818
To get started, submit your API key in the body of your request. api.video returns an access token that is valid for one hour (3600 seconds). A refresh token is also returned. View a [tutorial](https://api.video/blog/tutorials/authentication-tutorial) on authentication. All tutorials using the [authentication endpoint](https://api.video/blog/endpoints/authenticate)
1919

@@ -25,7 +25,7 @@ import ApiVideoUploader
2525

2626
let authenticatePayload = authenticate-payload(apiKey: "apiKey_example") // AuthenticatePayload |
2727

28-
// Authenticate
28+
// Advanced - Authenticate (1/2)
2929
AuthenticationAPI.authenticate(authenticatePayload: authenticatePayload) { (response, error) in
3030
guard error == nil else {
3131
print(error)
@@ -64,7 +64,7 @@ No authorization required
6464
open class func refresh(refreshTokenPayload: RefreshTokenPayload, completion: @escaping (_ data: AccessToken?, _ error: Error?) -> Void)
6565
```
6666

67-
Refresh token
67+
Advanced - Refresh token (2/2)
6868

6969
Use the refresh endpoint with the refresh token you received when you first authenticated using the api-key endpoint. Send the refresh token in the body of your request. The api.video API returns a new access token that is valid for one hour (3600 seconds) and a new refresh token.
7070

@@ -76,7 +76,7 @@ import ApiVideoUploader
7676

7777
let refreshTokenPayload = refresh-token-payload(refreshToken: "refreshToken_example") // RefreshTokenPayload |
7878

79-
// Refresh token
79+
// Advanced - Refresh token (2/2)
8080
AuthenticationAPI.refresh(refreshTokenPayload: refreshTokenPayload) { (response, error) in
8181
guard error == nil else {
8282
print(error)

project.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ targets:
77
sources: [Sources]
88
info:
99
path: ./Info.plist
10-
version: 1.0.0
10+
version: 1.0.1
1111
settings:
1212
APPLICATION_EXTENSION_API_ONLY: true
1313
scheme: {}

0 commit comments

Comments
 (0)