Skip to content

Commit 35e13f6

Browse files
committed
chore: release rc
1 parent 6d0eae5 commit 35e13f6

18 files changed

+370
-30
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Appwrite Ruby SDK
22

33
![License](https://img.shields.io/github/license/appwrite/sdk-for-ruby.svg?style=flat-square)
4-
![Version](https://img.shields.io/badge/api%20version-1.5.7-blue.svg?style=flat-square)
4+
![Version](https://img.shields.io/badge/api%20version-1.6.0-blue.svg?style=flat-square)
55
[![Build Status](https://img.shields.io/travis/com/appwrite/sdk-generator?style=flat-square)](https://travis-ci.com/appwrite/sdk-generator)
66
[![Twitter Account](https://img.shields.io/twitter/follow/appwrite?color=00acee&label=twitter&style=flat-square)](https://twitter.com/appwrite)
77
[![Discord](https://img.shields.io/discord/564160730845151244?label=discord&style=flat-square)](https://appwrite.io/discord)

appwrite.gemspec

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
Gem::Specification.new do |spec|
22

33
spec.name = 'appwrite'
4-
spec.version = '11.0.2'
4+
spec.version = '12.0.0-rc.1'
55
spec.license = 'BSD-3-Clause'
66
spec.summary = 'Appwrite is an open-source self-hosted backend server that abstract and simplify complex and repetitive development tasks behind a very simple REST API'
77
spec.author = 'Appwrite Team'
88
spec.homepage = 'https://appwrite.io/support'
9-
spec.email = 'team@appwrite.io'
9+
spec.email = 'team@localhost.test'
1010
spec.files = Dir['lib/**/*.rb']
1111

1212
spec.add_dependency 'mime-types', '~> 3.4.1'

docs/examples/account/delete-mfa-authenticator.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,5 @@ client = Client.new
1111
account = Account.new(client)
1212

1313
result = account.delete_mfa_authenticator(
14-
type: AuthenticatorType::TOTP,
15-
otp: '<OTP>'
14+
type: AuthenticatorType::TOTP
1615
)

docs/examples/functions/create.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,5 +31,5 @@ result = functions.create(
3131
template_repository: '<TEMPLATE_REPOSITORY>', # optional
3232
template_owner: '<TEMPLATE_OWNER>', # optional
3333
template_root_directory: '<TEMPLATE_ROOT_DIRECTORY>', # optional
34-
template_branch: '<TEMPLATE_BRANCH>' # optional
34+
template_version: '<TEMPLATE_VERSION>' # optional
3535
)

docs/examples/functions/download-deployment.md renamed to docs/examples/functions/get-deployment-download.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@ include Appwrite
55
client = Client.new
66
.set_endpoint('https://cloud.appwrite.io/v1') # Your API Endpoint
77
.set_project('&lt;YOUR_PROJECT_ID&gt;') # Your project ID
8-
.set_key('&lt;YOUR_API_KEY&gt;') # Your secret API key
8+
.set_session('') # The user session to authenticate with
99

1010
functions = Functions.new(client)
1111

12-
result = functions.download_deployment(
12+
result = functions.get_deployment_download(
1313
function_id: '<FUNCTION_ID>',
1414
deployment_id: '<DEPLOYMENT_ID>'
1515
)
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
require 'appwrite'
2+
3+
include Appwrite
4+
5+
client = Client.new
6+
.set_endpoint('https://cloud.appwrite.io/v1') # Your API Endpoint
7+
.set_project('&lt;YOUR_PROJECT_ID&gt;') # Your project ID
8+
9+
functions = Functions.new(client)
10+
11+
result = functions.get_template(
12+
template_id: '<TEMPLATE_ID>'
13+
)
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
require 'appwrite'
2+
3+
include Appwrite
4+
5+
client = Client.new
6+
.set_endpoint('https://cloud.appwrite.io/v1') # Your API Endpoint
7+
.set_project('&lt;YOUR_PROJECT_ID&gt;') # Your project ID
8+
9+
functions = Functions.new(client)
10+
11+
result = functions.list_templates(
12+
runtimes: [], # optional
13+
use_cases: [], # optional
14+
limit: 1, # optional
15+
offset: 0 # optional
16+
)

lib/appwrite.rb

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
require_relative 'appwrite/models/team_list'
2626
require_relative 'appwrite/models/membership_list'
2727
require_relative 'appwrite/models/function_list'
28+
require_relative 'appwrite/models/template_function_list'
2829
require_relative 'appwrite/models/runtime_list'
2930
require_relative 'appwrite/models/deployment_list'
3031
require_relative 'appwrite/models/execution_list'
@@ -76,6 +77,9 @@
7677
require_relative 'appwrite/models/team'
7778
require_relative 'appwrite/models/membership'
7879
require_relative 'appwrite/models/function'
80+
require_relative 'appwrite/models/template_function'
81+
require_relative 'appwrite/models/template_runtime'
82+
require_relative 'appwrite/models/template_variable'
7983
require_relative 'appwrite/models/runtime'
8084
require_relative 'appwrite/models/deployment'
8185
require_relative 'appwrite/models/execution'

lib/appwrite/client.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ def initialize
1515
'x-sdk-name'=> 'Ruby',
1616
'x-sdk-platform'=> 'server',
1717
'x-sdk-language'=> 'ruby',
18-
'x-sdk-version'=> '11.0.2',
19-
'X-Appwrite-Response-Format' => '1.5.0'
18+
'x-sdk-version'=> '12.0.0-rc.1',
19+
'X-Appwrite-Response-Format' => '1.6.0'
2020
}
2121
@endpoint = 'https://cloud.appwrite.io/v1'
2222
end

lib/appwrite/models/execution.rb

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ class Execution
1919
attr_reader :logs
2020
attr_reader :errors
2121
attr_reader :duration
22+
attr_reader :scheduled_at
2223

2324
def initialize(
2425
id:,
@@ -36,7 +37,8 @@ def initialize(
3637
response_headers:,
3738
logs:,
3839
errors:,
39-
duration:
40+
duration:,
41+
scheduled_at:
4042
)
4143
@id = id
4244
@created_at = created_at
@@ -54,6 +56,7 @@ def initialize(
5456
@logs = logs
5557
@errors = errors
5658
@duration = duration
59+
@scheduled_at = scheduled_at
5760
end
5861

5962
def self.from(map:)
@@ -73,7 +76,8 @@ def self.from(map:)
7376
response_headers: map["responseHeaders"].map { |it| Headers.from(map: it) },
7477
logs: map["logs"],
7578
errors: map["errors"],
76-
duration: map["duration"]
79+
duration: map["duration"],
80+
scheduled_at: map["scheduledAt"]
7781
)
7882
end
7983

@@ -94,7 +98,8 @@ def to_map
9498
"responseHeaders": @response_headers.map { |it| it.to_map },
9599
"logs": @logs,
96100
"errors": @errors,
97-
"duration": @duration
101+
"duration": @duration,
102+
"scheduledAt": @scheduled_at
98103
}
99104
end
100105
end

0 commit comments

Comments
 (0)